On 10/23/2003 11:41 AM Ivica Pavic wrote:
I'm trying to set the UTF-8 charset for the whole application. I'm using Struts/Tiles on Tomcat 4.1.27. For now the only way to achieve this was adding <[EMAIL PROTECTED] contentType="text/html; charset=utf-8"%> on EVERY Tile (JSP). It's a lot of copy/paste job and I'm sure there should be a more elegant way. I've tried several things:
1. Setting the controller contentType to "text/html; charset=UTF-8" in struts-config.xml
2. Adding <%request.setCharacterEncoding("UTF-8");%> in the master layout
3. Adding <META http-equiv="Content-Type" content="text/html; charset=UTF-8"> to Master layout's <HEAD>
BUT NOTHING WORKS except adding a page directive on every JSP fragment.
Anyone has that resolved?

Hi Ivica,
I upgraded to tomcat 5 recently partly because of this. If you use JSTL fmt taglibs, then it's only in tomcat5 that uses JSTL 1.1 that things are more manageable. You can specify it in the deployment descriptor for various URLs, or by locale.



Adam


--
struts 1.1 + tomcat 5.0.12 + java 1.4.2
Linux 2.4.20 RH9


--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]



Reply via email to