tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bugzi...@apache.org
Subject DO NOT REPLY [Bug 24308] - for charset="UTF8" request.getParameter("i1").getBytes() return non UTF8 bytes
Date Thu, 08 Jan 2004 21:01:19 GMT
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://nagoya.apache.org/bugzilla/show_bug.cgi?id=24308>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://nagoya.apache.org/bugzilla/show_bug.cgi?id=24308

for charset="UTF8" request.getParameter("i1").getBytes() return non UTF8 bytes





------- Additional Comments From apache.org@baggins.org  2004-01-08 21:01 -------
I believe I have just hit this problem - but on a POST request.
I had a form where the user entered a £ sign (UK currency symbol). When I
carried out a request.getParameter("myParam");, the result came through with the
funny "A" character preceding the currency symbol. Despite other reporters
descriptions of this only occurring on a GET - my form was definately a POST.
The workaround for me has been to use request.setCharacterEncoding("UTF8"); -
and now everything is fine. (Note: someone above reported this not to make any
difference - you *must* call this prior to making any calls to getParameter()
or, getReader() )
This was on tomcat 4.1.29

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


Mime
View raw message