Riccardo Cohen wrote:
> what do you suggest for strings localization ? the docs does not tell 
> how to use xml for resourcebundle... or how to change encoding for text 
> resource bundle...

One approach is to use the \u.... codes for any character outside 
Latin-1 (.... are the hex digits of the code point in the Unicode tables).

That may make your resource bundle file less than ideal in terms or 
readability, but you may chose that for robustness.  You may even want 
to use the \u.... codes for every non-ascii character if you don't want 
other user's errors to affect you.

The other approach is to get familiar with the class loading scheme for 
resource bundles and write your own implementation.  

> 2) receiving
> the html page specify charset=UTF-8 in head content, and when typing £ 
> sign I get C2 A3. I suppose it is utf8 even if not exactly the code you 
> gave.

Correct, typo on my part.

> With that string the search succeed, but with the chinese 
> character 务 it fails.

Fails, how?  I believe that is character 0x52a1 
<http://www.fileformat.info/info/unicode/char/52a1/index.htm>, which 
should be perfectly representable in Java's 16 bit characters.

> I added <character-encoding>utf-8</character-encoding> in resin.conf, 
> and it did some change (before that, the returned search string was not 
> equal to the sent search string). But the search still fails with 
> chinese char. Maybe this is an issue with amber/mysql ?

Possibly.  Hard to say from here.


resin-interest mailing list

Reply via email to