Re: [T5] 5.0.16 Spanish special characters

2008-12-05 Thread Ray
Ive tried to update the maven repos with the encoding param but there was
still no change, im going to leave it be for a while and come back to it.
Thanks again for everyones assistance.



On Thu, Dec 4, 2008 at 10:57 AM, Andy Pahne <[EMAIL PROTECTED]>wrote:

>
> That's whatI did as well, and it works here.
>
> Anyway: it also works, when the property files are ISO encoded (ASCII) and
> UTF-8 chars are properly escaped.
>
> Andy
>
>
>
> Jakub Vlasak schrieb:
>
>  Hi,
>>
>> i've had similar problem with slovak character, and I've solved it ba
>> adding
>> the UTF-8 encoding parameter to the java compiler.
>> Edit the pom.xml file, the maven-compiler-plugin like this:
>>
>>  
>>org.apache.maven.plugins
>>maven-compiler-plugin
>>
>>1.5
>>1.5
>>true
>>*UTF-8*
>>
>>
>>
>> Hope this will help.
>>
>> On Thu, Dec 4, 2008 at 10:08 AM, Ray <[EMAIL PROTECTED]> wrote:
>>
>>
>>
>>> I've put in logging on the java page when bringing back the message, and
>>> its
>>> coming out incorrectly with ? instead of the special characters, so its
>>> nothing to do with the html I believe.
>>>
>>> I've since learned that the fact that im using Windows may also be having
>>> an
>>> effect as it may be saving the file in a format that is unexpected by
>>> Tapestry, but im only hedging a guess there really.
>>>
>>> Thanks for the feedback so far, its been great.
>>>
>>>
>>>
>>>
>>> On Thu, Dec 4, 2008 at 1:44 AM, dh ning <[EMAIL PROTECTED]> wrote:
>>>
>>>
>>>
 That's true, native2ascii is unnecessarily any more.
 Try to locate the issue whether it is caused at server side or by html


>>> page
>>>
>>>
 encoding.
 What's that value in tapestry page.java level? If it is correct, then


>>> this
>>>
>>>
 should be the html encoding problem.
 2008/12/4 Thiago H. de Paula Figueiredo <[EMAIL PROTECTED]>



> Em Wed, 03 Dec 2008 14:58:39 -0300, Imants Firsts <[EMAIL PROTECTED]>
> escreveu:
>
> Hi Ray!
>
>
>> The properties files should be in ascii encoding and the unicode
>> characters should be escaped with \u, for example "\u0161" for
>>
>>
> š
>>>
>>>
 character. JDK comes with native2ascii tool that does the conversion.
>>
>>
>>
> That's not correct anymore. Since some Tapestry version I don't recall,
>
>
 the


> property files need to be UTF-8 encoded, so no conversion needs to be
>
>
 done.


> From http://tapestry.apache.org/tapestry5/guide/localization.html:
>
> "Properties File Charset
>
> Tapestry uses the UTF-8 charset when reading the properties files in a
> message catalog. This means that you don't have to use the Java
>
>
 native2ascii


> tool."
>
>
> --
> Thiago H. de Paula Figueiredo
> Independent Java consultant, developer, and instructor
> Consultor, desenvolvedor e instrutor em Java
> http://www.arsmachina.com.br/thiago
>
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>
>
>

>>
>>
>
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


Re: [T5] 5.0.16 Spanish special characters

2008-12-04 Thread Andy Pahne


That's whatI did as well, and it works here.

Anyway: it also works, when the property files are ISO encoded (ASCII) 
and UTF-8 chars are properly escaped.


Andy



Jakub Vlasak schrieb:

Hi,

i've had similar problem with slovak character, and I've solved it ba adding
the UTF-8 encoding parameter to the java compiler.
Edit the pom.xml file, the maven-compiler-plugin like this:

  
org.apache.maven.plugins
maven-compiler-plugin

1.5
1.5
true
*UTF-8*



Hope this will help.

On Thu, Dec 4, 2008 at 10:08 AM, Ray <[EMAIL PROTECTED]> wrote:

  

I've put in logging on the java page when bringing back the message, and
its
coming out incorrectly with ? instead of the special characters, so its
nothing to do with the html I believe.

I've since learned that the fact that im using Windows may also be having
an
effect as it may be saving the file in a format that is unexpected by
Tapestry, but im only hedging a guess there really.

Thanks for the feedback so far, its been great.




On Thu, Dec 4, 2008 at 1:44 AM, dh ning <[EMAIL PROTECTED]> wrote:



That's true, native2ascii is unnecessarily any more.
Try to locate the issue whether it is caused at server side or by html
  

page


encoding.
What's that value in tapestry page.java level? If it is correct, then
  

this


should be the html encoding problem.
2008/12/4 Thiago H. de Paula Figueiredo <[EMAIL PROTECTED]>

  

Em Wed, 03 Dec 2008 14:58:39 -0300, Imants Firsts <[EMAIL PROTECTED]>
escreveu:

Hi Ray!


The properties files should be in ascii encoding and the unicode
characters should be escaped with \u, for example "\u0161" for
  

š


character. JDK comes with native2ascii tool that does the conversion.

  

That's not correct anymore. Since some Tapestry version I don't recall,


the
  

property files need to be UTF-8 encoded, so no conversion needs to be


done.
  

From http://tapestry.apache.org/tapestry5/guide/localization.html:

"Properties File Charset

Tapestry uses the UTF-8 charset when reading the properties files in a
message catalog. This means that you don't have to use the Java


native2ascii
  

tool."


--
Thiago H. de Paula Figueiredo
Independent Java consultant, developer, and instructor
Consultor, desenvolvedor e instrutor em Java
http://www.arsmachina.com.br/thiago


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]





  



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [T5] 5.0.16 Spanish special characters

2008-12-04 Thread Jakub Vlasak
Hi,

i've had similar problem with slovak character, and I've solved it ba adding
the UTF-8 encoding parameter to the java compiler.
Edit the pom.xml file, the maven-compiler-plugin like this:

  
org.apache.maven.plugins
maven-compiler-plugin

1.5
1.5
true
*UTF-8*



Hope this will help.

On Thu, Dec 4, 2008 at 10:08 AM, Ray <[EMAIL PROTECTED]> wrote:

> I've put in logging on the java page when bringing back the message, and
> its
> coming out incorrectly with ? instead of the special characters, so its
> nothing to do with the html I believe.
>
> I've since learned that the fact that im using Windows may also be having
> an
> effect as it may be saving the file in a format that is unexpected by
> Tapestry, but im only hedging a guess there really.
>
> Thanks for the feedback so far, its been great.
>
>
>
>
> On Thu, Dec 4, 2008 at 1:44 AM, dh ning <[EMAIL PROTECTED]> wrote:
>
> > That's true, native2ascii is unnecessarily any more.
> > Try to locate the issue whether it is caused at server side or by html
> page
> > encoding.
> > What's that value in tapestry page.java level? If it is correct, then
> this
> > should be the html encoding problem.
> > 2008/12/4 Thiago H. de Paula Figueiredo <[EMAIL PROTECTED]>
> >
> > > Em Wed, 03 Dec 2008 14:58:39 -0300, Imants Firsts <[EMAIL PROTECTED]>
> > > escreveu:
> > >
> > > Hi Ray!
> > >>
> > >> The properties files should be in ascii encoding and the unicode
> > >> characters should be escaped with \u, for example "\u0161" for
> š
> > >> character. JDK comes with native2ascii tool that does the conversion.
> > >>
> > >
> > > That's not correct anymore. Since some Tapestry version I don't recall,
> > the
> > > property files need to be UTF-8 encoded, so no conversion needs to be
> > done.
> > >
> > > From http://tapestry.apache.org/tapestry5/guide/localization.html:
> > >
> > > "Properties File Charset
> > >
> > > Tapestry uses the UTF-8 charset when reading the properties files in a
> > > message catalog. This means that you don't have to use the Java
> > native2ascii
> > > tool."
> > >
> > >
> > > --
> > > Thiago H. de Paula Figueiredo
> > > Independent Java consultant, developer, and instructor
> > > Consultor, desenvolvedor e instrutor em Java
> > > http://www.arsmachina.com.br/thiago
> > >
> > >
> > > -
> > > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > > For additional commands, e-mail: [EMAIL PROTECTED]
> > >
> > >
> >
>


Re: [T5] 5.0.16 Spanish special characters

2008-12-04 Thread Ray
I've put in logging on the java page when bringing back the message, and its
coming out incorrectly with ? instead of the special characters, so its
nothing to do with the html I believe.

I've since learned that the fact that im using Windows may also be having an
effect as it may be saving the file in a format that is unexpected by
Tapestry, but im only hedging a guess there really.

Thanks for the feedback so far, its been great.




On Thu, Dec 4, 2008 at 1:44 AM, dh ning <[EMAIL PROTECTED]> wrote:

> That's true, native2ascii is unnecessarily any more.
> Try to locate the issue whether it is caused at server side or by html page
> encoding.
> What's that value in tapestry page.java level? If it is correct, then this
> should be the html encoding problem.
> 2008/12/4 Thiago H. de Paula Figueiredo <[EMAIL PROTECTED]>
>
> > Em Wed, 03 Dec 2008 14:58:39 -0300, Imants Firsts <[EMAIL PROTECTED]>
> > escreveu:
> >
> > Hi Ray!
> >>
> >> The properties files should be in ascii encoding and the unicode
> >> characters should be escaped with \u, for example "\u0161" for š
> >> character. JDK comes with native2ascii tool that does the conversion.
> >>
> >
> > That's not correct anymore. Since some Tapestry version I don't recall,
> the
> > property files need to be UTF-8 encoded, so no conversion needs to be
> done.
> >
> > From http://tapestry.apache.org/tapestry5/guide/localization.html:
> >
> > "Properties File Charset
> >
> > Tapestry uses the UTF-8 charset when reading the properties files in a
> > message catalog. This means that you don't have to use the Java
> native2ascii
> > tool."
> >
> >
> > --
> > Thiago H. de Paula Figueiredo
> > Independent Java consultant, developer, and instructor
> > Consultor, desenvolvedor e instrutor em Java
> > http://www.arsmachina.com.br/thiago
> >
> >
> > -
> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > For additional commands, e-mail: [EMAIL PROTECTED]
> >
> >
>


Re: [T5] 5.0.16 Spanish special characters

2008-12-03 Thread dh ning
That's true, native2ascii is unnecessarily any more.
Try to locate the issue whether it is caused at server side or by html page
encoding.
What's that value in tapestry page.java level? If it is correct, then this
should be the html encoding problem.
2008/12/4 Thiago H. de Paula Figueiredo <[EMAIL PROTECTED]>

> Em Wed, 03 Dec 2008 14:58:39 -0300, Imants Firsts <[EMAIL PROTECTED]>
> escreveu:
>
> Hi Ray!
>>
>> The properties files should be in ascii encoding and the unicode
>> characters should be escaped with \u, for example "\u0161" for š
>> character. JDK comes with native2ascii tool that does the conversion.
>>
>
> That's not correct anymore. Since some Tapestry version I don't recall, the
> property files need to be UTF-8 encoded, so no conversion needs to be done.
>
> From http://tapestry.apache.org/tapestry5/guide/localization.html:
>
> "Properties File Charset
>
> Tapestry uses the UTF-8 charset when reading the properties files in a
> message catalog. This means that you don't have to use the Java native2ascii
> tool."
>
>
> --
> Thiago H. de Paula Figueiredo
> Independent Java consultant, developer, and instructor
> Consultor, desenvolvedor e instrutor em Java
> http://www.arsmachina.com.br/thiago
>
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


Re: [T5] 5.0.16 Spanish special characters

2008-12-03 Thread Thiago H. de Paula Figueiredo
Em Wed, 03 Dec 2008 14:58:39 -0300, Imants Firsts <[EMAIL PROTECTED]>  
escreveu:



Hi Ray!

The properties files should be in ascii encoding and the unicode  
characters should be escaped with \u, for example "\u0161" for š  
character. JDK comes with native2ascii tool that does the conversion.


That's not correct anymore. Since some Tapestry version I don't recall,  
the property files need to be UTF-8 encoded, so no conversion needs to be  
done.


From http://tapestry.apache.org/tapestry5/guide/localization.html:

"Properties File Charset

Tapestry uses the UTF-8 charset when reading the properties files in a  
message catalog. This means that you don't have to use the Java  
native2ascii tool."



--
Thiago H. de Paula Figueiredo
Independent Java consultant, developer, and instructor
Consultor, desenvolvedor e instrutor em Java
http://www.arsmachina.com.br/thiago

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [T5] 5.0.16 Spanish special characters

2008-12-03 Thread Imants Firsts
Hi Ray!

The properties files should be in ascii encoding and the unicode characters 
should be escaped with \u, for example "\u0161" for š character. JDK 
comes with native2ascii tool that does the conversion.
I have seen an eclipse property editor plugin which saves properties files in 
this format, but I myself use the following ant script to convert them.










 

It can be configured to run automatically when a property file changes or run 
manually, or run by a build script.

This converts tapestry main properties file and other native (latvian) files 
under /src/main/native in the respective packages

You have to replace the encoding attribute with the encoding of your files, and 
update suffix (from _lv to _es). If you have more than one language that needs 
converting, you will have to get creative with that script.

Best Regards,
Imants

Quoting Ray <[EMAIL PROTECTED]>:
> Hi there,
> 
> I have a problem in parsing Spanish phrases with special chars. The
> original
> message defined is something like:
> 
> DESCRIPTION=Descripción
> 
> comes back as:
> 
> Descripti?n
> 
> from the Messages object. My file format is UTF-8 and my page has the
> appropriate header defined.
> 
> Is there something completely obvious im missing here? Ive tried various
> workrounds, such as defining the unicode escape chars for the special
> chars
> which work for the web page. Problem then is in populating values in a
> dropdown menu where all the unicode escape chars come back as their
> literal
> string equivalents.
> 
> Cheers,
> 
> Ray.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]