struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From riffla <>
Subject Re: Character encoding...
Date Fri, 23 Mar 2007 20:32:19 GMT

Of course, forgot to mention, mainly I mean as output on a JSP page (both
bean:write and <%=...%>, but also System.out.println() in different places,
always the same result...


Christopher Schultz-2 wrote:
> Hash: SHA1
> Riffla,
> riffla wrote:
>> Sending a request form a JSP using ISO-8859-1 with POST method (no
>> problem
>> using GET method or UTF-8 on origin page) to either a Struts action or
>> another JSP (with either UTF-8 or ISO-8859-1, tried both) replaces my å,ä
>> and ö with '?'
> Where do you see the '?'? In a web page? In a log file? In the results
> of a database query from a command-line tool? It's possible that your
> output isn't sensitive to the character encoding (for instance, a
> terminal window or log file).
>> even though I've set the Connector property (Tomcat as
>> server) to UTF-8.
> URIEncoding="UTF-8" only affects the interpretation of the URL string in
> the request, not the body of the request. The body of the request is
> interpreted using the content-type HTTP header.
>> So the problem seems to happen with the POST data in the
>> request when going from ISO to UTF using POST method...
> If you are submitting data with a content-type of ISO-8859-1 and then
> forcing the request's encoding to be UTF-8, then you are introducing the
> problem yourself. ISO != UTF-8, so you shouldn't be doing that. If you
> really need to use non-ASCII characters at all, then you should convert
> everything to UTF-8. Make sure that all your pages use UTF-8 as the
> response encoding, and all POST forms should then use UTF-8 as the
> request body encoding.
> - -chris
> Version: GnuPG v1.4.7 (MingW32)
> Comment: Using GnuPG with Mozilla -
> ZupLQFeCLlyi/kit/l9EDxo=
> =Gwxy
> ---------------------------------------------------------------------
> To unsubscribe, e-mail:
> For additional commands, e-mail:

View this message in context:
Sent from the Struts - User mailing list archive at

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message