this is my second day using wicket from struts/springmvc and I need wicket to
set up so that every request (maybe this is an old thinking?) must follow
the browser's locale.  for pages, I could easily enough to have a base page
and in its contructor do the following:

     Locale locale = getRequest().getLocale();
     locale = doSomething( locale );  // e.g. substituting non-supported
locale
     getSession().setLocale( locale );

and this works fine.  however, for button's onSubmit() wicket uses the
existing page instead of creating a new one and so my code in the base page
constructor's is not run.  copying my code into every handler is one option. 
subclassing all such components is another.  neither seems particularly
appealing for me.

I've looked at replacing standard classes (session, etc.) or overriding some
WebApplication methods, even subsclassing the WicketFilter itself, but I
still couldn't find a place where I have both the session & request objects
to do the locale setting.  being newbie, I probably missed reading some docs
somewhere or some posts in this forum (searched "locale", "request", etc.)

thanks for any help enlightening me on this hurdle.

iwanj
-- 
View this message in context: 
http://www.nabble.com/setting-session-locale-to-browser-locale-on-onSubmit%28%29-tp15229868p15229868.html
Sent from the Wicket - User mailing list archive at Nabble.com.


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

Reply via email to