I had problem with character encoding in my web application. I was trying to
display Polish characters using UTF-8 but data from forms was not getting in
proper format to the business layer. I managed to solve this by setting
filter which does request.setCharacterEncoding(encoding); But the question
is: WHY it didn't work when I was using request.setCharacterEncoding() in
Action's execute() method??
The request's character encoding can only be set before the input
values are read. By the time the Action executes, the ActionForm has
already been populated, which means that the request has already
deserialized the request parameters from bytes on the wire into Java
Strings. Thus, a ServletFilter is the best way to make sure that
this value is set at the earliest possible time.
Hope this helps,
Joe
--
Joe Germuska
[EMAIL PROTECTED]
http://blog.germuska.com
"Narrow minds are weapons made for mass destruction" -The Ex
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]