[
Date Prev][
Date Next][
Thread Prev][
Thread Next][
Date Index][
Thread Index]
[
List Home]
Re: [jetty-users] ISO-8859-Encoded request-parameters
|
Martin,
This page contains info on handling url encoding with jetty 6, but is
still relevant to jetty 7:
http://docs.codehaus.org/display/JETTY/International+Characters+and+Character+Encodings
The name of the System property for changing the default encoding of
urls is now:
"org.eclipse.jetty.util.URI.charset"
regards
Jan
Martin Below wrote:
Hello,
I'm facing a problem with iso-8859-1 encoded get-parameters containing
German umlauts. I'm using jetty 7.0.1.v20091125.
I found a few related issues in the jira (e.g.
http://jira.codehaus.org/browse/JETTY-633), but they are all marked as
resolved.
I also tried setting the character encoding manually (using
ServletRequest.setCharacterEncoding() as suggested in
http://jira.codehaus.org/browse/JETTY-1098), without success.
Here is the exception I get:
java.lang.IllegalArgumentException: !utf8
at
org.eclipse.jetty.util.Utf8StringBuilder.append(Utf8StringBuilder.java:122)
at org.eclipse.jetty.util.UrlEncoded.decodeUtf8To(UrlEncoded.java:292)
at org.eclipse.jetty.http.HttpURI.decodeQueryTo(HttpURI.java:561)
at
org.eclipse.jetty.server.Request.extractParameters(Request.java:204)
at
org.eclipse.jetty.server.Request.getParameterMap(Request.java:659)
[...]
I had a quick look at the source. As far as I understand,
httpURI.decodeQueryTo(MultiMap) does not pay attention to the encoding,
and always delegates to UrlEncoded.decodeUtf8To(...)
UrlEncoded.decode88591To(...) is never called.
Or am I missing something?
Thanks,
Martin
------------------------------------------------------------------------
_______________________________________________
jetty-users mailing list
jetty-users@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/jetty-users
--
Jan Bartel, Webtide LLC | janb@xxxxxxxxxxx | http://www.webtide.com