David Delbecq wrote:
> Hi mark, not at all
> 
> 1) there are 20 results for Djavax.servlet.request.encoding in google ^^
> (but am really not sure this parameter really exists in tomcat)

My bad. I kept the "-" in front which, of course, suppressed the
results. The option isn't in the spec and isn't in the 5.5.x code
base. Maybe it is an option from an old version since the only
references appear to be Tomcat related.

> 2) URIEncoding="UTF-8" set the encoding used for html link, the default
> is platform dependent.

Indeed, which is why I mentioned it. As per the docs and the spec, the
default is always ISO-8859-1 regardless of the platform default
encoding. Any query parameters in the URL will be decoded on this
basis. request.setEncoding() has no effect on this unless
useBodyEncodingForURI="true" is set on the connector.

> The only way i know to solve it is to write a small
> servlet filter that issue a request.setEncoding("UTF-8")

You can make the same call within a JSP or servlet. Where makes most
sense will vary from application to application.

The other place where encoding can trip you up is if you include
static resources within a JSP. There is a fileEncoding parameter on
the default servlet that may help.

Mark

Mark

---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to