tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Adam Hardy <ahardy.str...@cyberspaceroad.com>
Subject configuration of page encoding in tomcat 5
Date Sat, 04 Oct 2003 18:40:41 GMT
I'm testing the character encoding configuration in tomcat 5 in the 
deployment descriptor.

I'm using Struts - Tiles servlets and normal JSPs.

I'm using the <locale-encoding-mapping-list/> and the <jsp-config/> .

If I leave out the pageEncoding page directive from the JSPs and I leave 
out the <page-encoding> tag from the <jsp-config>, with the 
configuration below, the returned content-type http header is purely 
'text/html' with no character set.

I.e. tomcat ignores the <locale-encoding-mapping-list/>

Is this intentional? Is the <locale-encoding-mapping-list/> overriden by 
the JSP page, which has no page encoding set?



I've got the following config:

   <jsp-config>
     <jsp-property-group>
       <description>
         Trial run
       </description>
       <display-name>Geronimo!</display-name>
       <url-pattern>/WEB-INF/general/*</url-pattern>
       <el-ignored>false</el-ignored>
       <scripting-invalid>false</scripting-invalid>
       <is-xml>false</is-xml>
     </jsp-property-group>
   </jsp-config>

   <locale-encoding-mapping-list>
     <locale-encoding-mapping>
       <locale>en</locale><encoding>ISO-8859-1</encoding>
     </locale-encoding-mapping>
     <locale-encoding-mapping>
       <locale>de</locale><encoding>ISO-8859-15</encoding>
     </locale-encoding-mapping>
   </locale-encoding-mapping-list>

I'm using

wget -S --header='Accept-Language: de' http://localhost:8080/home.do

to read the headers, if that makes any difference.

Adam


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


---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org


Mime
View raw message