Win a copy of Think Java: How to Think Like a Computer Scientist this week in the Java in General forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Including localized static files

 
Peter Laurinec
Ranch Hand
Posts: 52
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi all.
Do any of you guys know the way, how can I include static text blocks (files) according to locale of the user accessing the page?

Example:
User with english locale enters, I want to include file 'intro_en.jsp'
User with slovak locale, include 'intro_sk.jsp'

Is there any way in struts how to achieve this ?

I really appreciate any responce you can give me. Thx
 
Merrill Higginson
Ranch Hand
Posts: 4864
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Struts doesn't handle internationalization in quite this way. With struts, you define keys for text that is displayed on a jsp, and then have different properties files for each language you support. With Struts, though, you would normally have just one Jsp file.

Just go to Google and key in "Struts internationalization" and you'll see several good links on how to support multiple languages in Struts.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic