• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Problem with fmt

 
Ranch Hand
Posts: 118
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I have properties files. Want to use the properties in the javascript alerts.
Now, when i type chinese characters in the propeties file,and rebuild. The properties in the classses display '???'.

I use WSAD. Is ths the problem wth the rebuild in WSAD? or there are some setiings to prevent this.

Initially i thought it was something like 'escapeXML' in <c ut />, but it turned to be an altogether different problem.
 
Sheriff
Posts: 13411
Firefox Browser VI Editor Redhat
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Moving to the JSP forum where the JSTL gurus hang out.
 
Ranch Hand
Posts: 34
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
u have to use internationalization for that use Locale and resource bundle classes for that
 
Bartender
Posts: 1845
10
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
You have chinese characters in your properties file?
Try running it through the native2ascii tool (comes standard with java) to convert it from whatever character set you are using for the properties file, into standard unicode escape characters.

For instance if your properties file is in UTF-8
native2ascii -encoding UTF8 oldFile.properties newFile.properties
http://java.sun.com/j2se/1.5.0/docs/tooldocs/index.html#intl

Hope this helps,
evnafets
 
geeta lalchandani
Ranch Hand
Posts: 118
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
in that case, the fmt would not work without the properties conversion. I also tried to create a txt file with proper encodings.
 
Attractive, successful people love this tiny ad:
a bit of art, as a gift, that will fit in a stocking
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic