You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by Inandjo Taurel <in...@hotmail.com> on 2006/05/04 19:33:42 UTC

How to manually force the use of an ApplicationResources.properties??

hi,

I'm using struts 1.2.8 along with JSPs in an application.
As at now for the internationalization, I'm just using the normal mechanism 
just by specifying the path to the resources file in my struts config file, 
and getting <bean:message key=".."/>.

Now, I need to be able to switch from one file to another just by clicking a 
link; ie when I click a link, the application resource file to be used by 
the system should be the french one, and when i click on another link, I 
should be using the english resource files for example.
I just want to be able to switch language on the click of a link, not depend 
on LOCAL.

I googled it, but didnt quite find what I was looking for, or anything close 
to it.

Thanx



---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org


Re: How to manually force the use of an ApplicationResources.properties??

Posted by Niall Pemberton <ni...@gmail.com>.
On 5/4/06, Inandjo Taurel <in...@hotmail.com> wrote:
> hi,
>
> I'm using struts 1.2.8 along with JSPs in an application.
> As at now for the internationalization, I'm just using the normal mechanism
> just by specifying the path to the resources file in my struts config file,
> and getting <bean:message key=".."/>.
>
> Now, I need to be able to switch from one file to another just by clicking a
> link; ie when I click a link, the application resource file to be used by
> the system should be the french one, and when i click on another link, I
> should be using the english resource files for example.
> I just want to be able to switch language on the click of a link, not depend
> on LOCAL.
>
> I googled it, but didnt quite find what I was looking for, or anything close
> to it.

This is done in Struts by storing the Locale in the users sesssion -
so when you click on the "French" link, it puts the French Locale in
the users session. The struts-examples webapp (shipped with the binary
distro) does this.

Niall

> Thanx

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org