DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG· RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT <http://issues.apache.org/bugzilla/show_bug.cgi?id=32242>. ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND· INSERTED IN THE BUG DATABASE.
http://issues.apache.org/bugzilla/show_bug.cgi?id=32242 Summary: Override default locale per application Product: Struts Version: 1.2.4 Platform: PC OS/Version: Linux Status: NEW Severity: enhancement Priority: P2 Component: Controller AssignedTo: [EMAIL PROTECTED] ReportedBy: [EMAIL PROTECTED] As far as I understand it - the struts framework will set the locale in the users session to Locale.getDefault() when 1) The session value for locale is not already set and 2) The users browser has not sent an Accept-Language header So - to set a default locale for an application you need to set the default locale for the application's JVM. Under JBoss (maybe others) - one JVM is shared across applications. This means that it is not possible to handle the situation where one struts app needs lang1 as default and one struts app needs lang2 as default. Concrete example App1 has the following property files (and should default to english) app1.properties (in english) app1_no.properties (norwegian) app1_da.properties (danish) App2 has the following property files (and should default to norwegian) app2.properties (in norwegian) app2_en.properties (english) System locale is english. This means that app2 actually defaults to english since system locale is in english and app2 has an english properties file. It would be nice to be able to set at struts-config.xml level (perhaps controller section) an <default-language>no</default-language> so that you can override the default locale on a per application basis. Note - all other locale based stuff is working well - this is just talking about the initialisation of the session locale based on default locale. -- Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are the assignee for the bug, or are watching the assignee. --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]