File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
Win a copy of Clojure in Action this week in the Clojure forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

How to force encoding of web browser to UTF-8

 
Ngo Hoang Minh
Greenhorn
Posts: 2
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Dear all,

I used tiles of Struts 1.1 and WebSphere. How I force encoding of browser to UTF-8 ? I used an filter to set content type of response to "text/html; charset=UTF-8" - response.setContentType("text/html; charset=UTF-8")
I also set character encoding of request to "UTF-8" - request.setCharacterEncoding("UTF-8") in this filter
I also set <meta http-equiv="content-type" content="text/html; charset=utf-8" /> at template JSP file

but when I run my application, the encoding of web browser (both IE and Fire Fox) did not force to UTF-8

Please help me

Best regards,
 
Chris Boldon
Ranch Hand
Posts: 190
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
In the top of your JSP:

 
I agree. Here's the link: http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic