Simply include a parameter in the request, either from a link or a form, that sets the requst_locale
parameter to the language and (optionally) counry code to use.
Code Block |
---|
<h3>Language Options</h3> <ul> <li><a <li><html:linkhref="<s:url action="/Locale?languageWelcome?request_locale=en"/>">English</html:link><a></li> <li><a <li><html:linkhref="<s:url action="/Locale?languageWelcome?request_locale=ja" useLocalEncoding="true"> Japanese</html:link></>">Japanese</a></li> <li><html:link<li><a href="<s:url action="/Locale?languageWelcome?request_locale=ru" useLocalEncoding="true"> Russian</html:link></>">Russian</a></li> </ul> |
The default interceptor stack includes an i18n interceptor that watches for the request_locale
parameter. The parameter name is configurable.