On Wed, Oct 20, 2010 at 20:05, sam lee <[email protected]> wrote:
> <form method="POST" action="/some/path"
>    accept-charset="utf-8"
>    enctype="application/x-www-form-urlencoded; charset=utf-8">
>    <input type="hidden" name="_charset_" value="UTF-8" />
>    <input type="submit" value="Save" />
> ...
>
> Then I would expect request.getCharacterEncoding()  (from POST.jsp) to
> return "UTF-8". But it still returns "ISO-8859-1".

Have you validated what is actually sent in the HTTP request?

> Or, browsers don't send request body encoding information?

Browsers don't send it (at least not reliable). Simply always use
_charset_, it is the most stable solution you can find.

Regards,
Alex

-- 
Alexander Klimetschek
[email protected]

Reply via email to