File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes Servlets and the fly likes Internationalization of dynamic content Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Servlets
Bookmark "Internationalization of dynamic content" Watch "Internationalization of dynamic content" New topic

Internationalization of dynamic content

Gavi Raaghav
Ranch Hand

Joined: Apr 28, 2005
Posts: 82
We are developing a web app using Struts and WAS 5.1. The requirement is that the user can input data in multiple languages like english,japanese and the same needs to be displayed back according to the locale of the user.
Static data is not a problem as its getting rendered properly through resource bundle.
I am storing data in UTF-8 format in the database.
For dynamic data I�ve created a filter which intercepts every request and converts the encoding to UTF-8.
When I am retrieving the property corresponding to Japanese character in my action class, its not coming in proper format.
I.e. JVM is not able to recognize the proper format.
One thing, when I am directly providing some Japanese character (copy & paste) in the SQL server database, then on the front end, it is displayed in proper format.
I.e. things are working fine from back end to front end but not vice-verca.
So I am not sure whether problem is with request-response or from JVM side!!

I am sure i am missing something while sending the data from the front end to the DB so that its not getting stored in UTF-8 format.
Any pointers will be highly appreciated.
I agree. Here's the link:
subject: Internationalization of dynamic content
It's not a secret anymore!