Win a copy of Programmer's Guide to Java SE 8 Oracle Certified Associate (OCA) this week in the OCAJP forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

how to check i18n application for different language

 
dhanaji sawant
Greenhorn
Posts: 3
  • Likes 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
i have made one program in sturts in which i have made 3 applicationResource.en_US.properties and other language applicationResource.it_IT.properties and now i have to test these language support in my browser but it language is english so it disply on english ...i want to test for other language so tell me the procedure...
 
Tim Storms
Ranch Hand
Posts: 64
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Have you tried to change the language setting of your browser?

In Firefox e.g. goto Extra - Properties - Advanced settings - Language - Change language (my browser isn't english so I guessed these words... :-)).

That should do the trick. ;-)
 
Merrill Higginson
Ranch Hand
Posts: 4864
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
In Microsoft Internet Explorer it's tools-->internet options. Then select the "General" tab and click the "Languages" button. You can add any number of languages, but make sure the language you want to test is at the top of the list.
 
Sofortstart sheldon
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have a struts application. It needs to be changed from english to german and viceversa when a button is pressed. How can I do that.
 
Sofortstart sheldon
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
No,it should not be externally set using Microsoft Internet Explorer it's tools-->internet options. Just locale in the application has to be changed I guess. I have'nt implemented any code for it yet.
 
Sp Wong
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
on button click, pass in the selected language in the param. Then, you can do the following:

 
jatan bhavsar
Ranch Hand
Posts: 299
Eclipse IDE Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

You dont need to set the locale in the browser. you have to set the locale through code only based on which struts will load the properties file.
Setting language option in browser is wrong.

Refer this.

Regards
Jatan

 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic