tomcat-taglibs-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Tim Dawson <>
Subject i18n: SJIS and MessageFormat
Date Fri, 15 Jun 2001 19:47:02 GMT
I'm using the i18n bundle (ok, I originated it) but I'm having a problem I
hope someone else may have a clue about.

The properties file I'm using for Japanese is encoded in Shift-JIS, and all
the japanese characters look great when they display on my test "echo all
key/value pairs" jsp page.

However, a few of the keys cause MessageFormat to explode with an
IllegalArgumentException related to "unmatched braces".  I've looked in the
properties file and indeed, a few unmatched braces are in there -- but only
as a accidental occurence for the first or second byte of the two-byte
encoding of shift-JIS.

So, I read a little further and see that I'm "supposed" to be using the
native2ascii tool. I put this into place, and yup, my properties file has a
bunch of unicode in it now - and no unmatched braces - but the web page that
uses that properties file now comes out as complete jibberish.

Where do I go from here? It appears that the either there's a bug in the jdk
or the docs are bad - or I'm completely missing something. Any ideas which
it might be? (I'm hoping its something I'm doing wrong)



View raw message