Hi,

Thanks for setting me in the right direction. It works!

-Jatinder

-----Original Message-----
From: Volker Weber [mailto:[EMAIL PROTECTED]
Sent: Thursday, October 20, 2005 11:31 AM
To: MyFaces Discussion
Subject: Re: Change Locale


Hi,

you need to specifiy the locale to a bean in f:view tag and change the
value there also.

Jatinder Singh wrote:
> Hi,
> 
> I'm trying to change the locale for the current user like this:
> 
> JSP:
> <h:commandLink immediate="true" action="#{Home.germanLocal}">
>       <h:graphicImage value="/german_flag.gif"/>
> </h:commandLink>
> 
> 
> PageBean:
> 
> public void germanLocal()
> {
>       
> FacesContext.getCurrentInstance().getViewRoot().setLocale(Locale.GERMAN);
> }
> 
> It changes the local for the current page but when I navigate to another page 
> it is changed back to the default.
> 
> Am I missing something here?
> 
> Thanks
> Jatinder
> 

-- 
Don't answer to From: address!
Mail to this account are droped if not recieved via mailinglist.
To contact me direct create the mail address by
concatenating my forename to my senders domain.

Reply via email to