You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@wicket.apache.org by Igor Vaynberg <ig...@gmail.com> on 2010/07/01 07:29:55 UTC

Re: difference between getSession().getLocale() and getRequest().getLocale()

not sure why they would be different unless you explicitly change it
in Session. when the session is created it sets its locale from the
request by default:

public Session(Request request) {
...
locale = request.getLocale();
...
}

-igor
On Wed, Jun 30, 2010 at 2:02 AM, David Meulemans
<me...@gmail.com> wrote:
> Hi
>
> I've noticed a difference in getting the locale from the request and from
> the session.
> getSession().getLocale() shows "en"
> but getRequest().getLocale() shows "en_GB". thus not only the language but
> also the country.
>
> Why is this, or what am I doing wrong perhaps?
> Are there maybe other drawbacks related to the use of one of these?
>
> I'm using wicket 1.4.1
>
> grtz
>

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org