Hi Cyril,

In your Action class call setLocale (HttpServletRequest request, Locale
locale). Use your jsp to get the country code ie 'fr'. You can then use this
code in your action to create the locale, ie Locale locale = new Locale
(code). Once you have set the locale struts will take care of the rest; you
just need to define a resource bundle for each locale.

Hope this helps, let me know if you need help with the jsp side of things.

Jon Ridgway


-----Original Message-----
From: cyril guszkiewicz [mailto:[EMAIL PROTECTED]] 
Sent: 10 July 2002 11:23
To: [EMAIL PROTECTED]
Subject: Switching the locale(language)


Hi everybody, I'am developping an application in three languages with STUTS
1.0.2

I'd like to know how can you change the locale of an application via a
button on a web page.I don't want the user to have to change their language
from the browser (e.g. Tools-Internet Options-Languages in IE) but I want
the user to be able to toggle languages from a button.

Thanks a lot for yours answers ( if you could give me an example it would be
nice)

Bye



---------------------------------
Yahoo! Mail -- Une adresse @yahoo.fr gratuite et en français !

The contents of this email are intended only for the named addressees and
may contain confidential and/or privileged material. If received in error
please contact UPCO on +44 (0) 113 201 0600 and then delete the entire
e-mail from your system. Unauthorised review, distribution, disclosure or
other use of this information could constitute a breach of confidence. Your
co-operation in this matter is greatly appreciated. 

--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to