velocity-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Daniel Dekany <ddek...@freemail.hu>
Subject Re: encoding problem
Date Sun, 28 Aug 2005 18:31:26 GMT
Friday, August 26, 2005, 3:38:26 PM, Bayarsaikhan VOLODYA wrote:

> hi,
>
> i have an encoding problem. in my velocity.properties
>
> input.encoding=UTF-8
> output.encoding=UTF-8
>
> and i cannot get Turkish(ISO-8859-9) inputs from text fields. it becomes
> something like this : ÜĞP,İŞ.Ö
>
> when i change my velocity.properties to
>
> input.encoding=ISO-8859-9
> output.encoding=ISO-8859-9
>
> all turkish characters become : ???????
>
>
> what can i do?

Look as when the Servlet container decodes the input with the wrong
charset (so it has nothing to do with Velocity), probably with
ISO-8859-1. To fix this, you have to call
ServletRequest.setCharacterEncoding(theEncodingOfTheHTMLThatContainsTheForm).
This call must be done before any parameter is read from the
ServletRequest, or else it has no effect.

-- 
Best regards,
 Daniel Dekany


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


Mime
View raw message