Note that there are some explanatory texts on larger screens.

plurals
  1. POFrench Characters in JSF-primefaces Application shows Mojibake
    primarykey
    data
    text
    <p>In my Application I made it to have it in two languages. English and French. In English, its all right. But while Reading the Properties file for French Language it ends up showing mojibake. I have in my properties file like this: <code>example.french.char=é</code></p> <p>but it does not show properly in the application. I am viewing my app in Windows. I dont want to replace the French characters by Unicode characters. I want them to be read from properties file as they normally appear.</p> <p>How can I make it work? Please suggest. Can I make it happen to view the French Characters without using Unicodes?</p> <p>My properties file is encoded in UTF-8. Please suggest! </p> <p>I tried the following too..</p> <pre><code>public class CharacterEncodingFilter implements Filter{ private FilterConfig config; @Override public void destroy() { setConfig(null); } @Override public void doFilter(ServletRequest request, ServletResponse response, FilterChain filter) throws IOException, ServletException { request.setCharacterEncoding("UTF-8"); response.setCharacterEncoding("UTF-8"); response.setContentType("text/html; charset=UTF-8"); filter.doFilter(request, response); } @Override public void init(FilterConfig config) throws ServletException { setConfig(config); } public FilterConfig getConfig() { return config; } public void setConfig(FilterConfig config) { this.config = config; } } </code></pre> <p>and added this in web.xml</p> <pre><code>&lt;filter&gt; &lt;filter-name&gt;charEncoding_Filter&lt;/filter-name&gt; &lt;filter-class&gt;com.edfx.tum.filter.CharacterEncodingFilter&lt;/filter-class&gt; &lt;/filter&gt; &lt;filter-mapping&gt; &lt;filter-name&gt;charEncoding_Filter&lt;/filter-name&gt; &lt;url-pattern&gt;/*&lt;/url-pattern&gt; &lt;/filter-mapping&gt; </code></pre> <p>but still it shows mojibake.</p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload