Java Mailing List Archive

http://www.junlu.com/

Home » Home (12/2007) » Tomcat Users »

Re: problem with arabic in multilanguage jsp

Christopher Schultz

2004-01-14

Replies:

Thomas,

> we are running a tomcat instance that uses common jsps for all languages. If
> no encoding is set in the http-header tomcat 4.1.29 sets iso-8859-1 by
> default. Arabic users must then configure their browsers themselves
> (unacceptable).
>
> (1)
> If I set the encoding in the jsp like this:
> <%@(protected)"%>
> everything is fine. But as I told, our jsps are multilingual.
>
> (2)
> If I set the encoding in the jsp like this:
> <%
>  response.setContentType("text/html;charset=windows-1256");
> %>
> the results are just question marks. The same thing happens if the arabic
> text is not hardcoded in the jsp but comes from a varable.

Have you tried using:
<META HTTP-EQUIV="Content-Type" CONTENT="text/html;charset=windows-1256" />

Does this trigger the browser to display the text properly? If so, you
might consider adding this for some languages (like Arabic).

-chris

---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@(protected)
For additional commands, e-mail: tomcat-user-help@(protected)



©2008 junlu.com - Jax Systems, LLC, U.S.A.