velocity-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Sandeep kamath" <skam...@sapient.com>
Subject RE: Encoding Problem
Date Tue, 03 May 2005 10:27:01 GMT
Hi Daniel,
          Many Thanks. I did try ISO-8859-7 but it still wont work. I
get junk characters on the output stream. 

I used Velocity.getTemplate("<template file name>", "ISO-8859-7");

The template file is in ISO-8859-7 encoding. It still wont work.

Regards,
Sandeep


        

-----Original Message-----
From: Daniel Dekany [mailto:ddekany@freemail.hu] 
Sent: Tuesday, May 03, 2005 2:46 PM
To: Velocity Users List
Subject: Re: Encoding Problem

Tuesday, May 3, 2005, 9:26:21 AM, Sandeep kamath wrote:

> Hi,
>   I am quite new to Velocity. My requirement is that I need to process
a
> template that has greek characters in it. The current encoding used in
> my Java code is "UTF-8" which doesn't work.
>
> Has anyone used Velocity for Greek and is yes, whats the encoding that
> needs to be used?

ISO-8859-7 (or maybe cp1253 if you are writing an MS Windows-only app).
UTF-8 should work as well, just then you need a text editor that knows
UTF-8 (for the editing of the templates), which can be a problem
nowadays.

Note that there are two technically separated encodings playing here:
the encoding of the template files, and the encoding of the output, if
you are using an OutputStream at the end. Maybe use ISO-8859-7 for both,
or UTF-8 for the last.

> Regards,
> Sandeep

-- 
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


---------------------------------------------------------------------
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