You are viewing a plain text version of this content. The canonical link for it is here.
Posted to jetspeed-user@portals.apache.org by Marian Skalsky <ms...@euromove.sk> on 2002/09/17 15:05:12 UTC

JetspeedLocalization_XX.properties ENCODING problem

Hi there!

As today I'm mysteriously unable to *SEARCH* in the jetspeed mail archive and I need to solve this think briefly I'm asking here.

I wrote my own localized JetspeedLocalization_sk.properties file and put it in to right directory. I got my messages in the jsp page, so the file works. The problem is:
1) When I read JetspeedLocalization_sk.properties in windows notepad, everithing looks ok (all special characters look ok).
2) When I put text used in JetspeedLocalization_sk.properties file in to the html document, set the <meta http-equiv=Content-Type content="text/html; charset=windows-1250"> and wiev it, it works fine.
3) BUT, when I wanna browse jetspeed (WEB-INF\templates\vm\layouts\html\defaut.vm) it comes with UTF-8 encoding and when I switch it in to windows-1250, almost all characters crashe at all.

I tried to change some properties in TurbineResources and JetspeedResources.. but I can't get it work properly.
Please tell me if you know, this is probably common problem:
1) How should I encode my JetspeedLocalization_sk.properties file and set the /conf (which) files to get it work.
2) Is a velocity templating services touching the encoding of templates..?

Thank you very much.
$kala.



Re: JetspeedLocalization_XX.properties ENCODING problem

Posted by Shinsuke SUGAYA <sh...@yahoo.co.jp>.
Hi,

> Hi there!
> 
> As today I'm mysteriously unable to *SEARCH* in the jetspeed mail archive and I need to solve this think briefly I'm asking here.
> 
> I wrote my own localized JetspeedLocalization_sk.properties file and put it in to right directory. I got my messages in the jsp page, so the file works. The problem is:
> 1) When I read JetspeedLocalization_sk.properties in windows notepad, everithing looks ok (all special characters look ok).
> 2) When I put text used in JetspeedLocalization_sk.properties file in to the html document, set the <meta http-equiv=Content-Type content="text/html; charset=windows-1250"> and wiev it, it works fine.
> 3) BUT, when I wanna browse jetspeed (WEB-INF\templates\vm\layouts\html\defaut.vm) it comes with UTF-8 encoding and when I switch it in to windows-1250, almost all characters crashe at all.
> 
> I tried to change some properties in TurbineResources and JetspeedResources.. but I can't get it work properly.
> Please tell me if you know, this is probably common problem:
> 1) How should I encode my JetspeedLocalization_sk.properties file and set the /conf (which) files to get it work.

In Japanese properties file, I create it by native encoding
and convert from a native character to ASCII by "native2ascii" command. 

> 2) Is a velocity templating services touching the encoding of templates..?

Please see the following comment:

--------------------------------------------------------------------
Encoding configuration

 If you would like to use Multi-byte character, such as CJK characters, 
 you will need to modify the encoding parameters in:

  o <jetspeed_home>/WEB-INF/conf/JetspeedResources.properties:

    content.defaultencoding=<encoding>

  o <jetspeed_home>/WEB-INF/conf/TurbineResources.properties:

    services.VelocityService.input.encoding=<encoding>

 For examples, if you use UNIX in Japanese environment, <encoding> 
 will be UTF-8 or EUC-JP.

--------------------------------------------------------------------

I think that it works if you use UTF-8...

Thanks,
 shinsuke

> 
> Thank you very much.
> $kala.
> 
> 



__________________________________________________
Do You Yahoo!?
Yahoo! BB is Broadband by Yahoo!  http://bb.yahoo.co.jp/


--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>