Results 1 to 3 of 3

Thread: Setting locales in jstl views

  1. #1
    Join Date
    Aug 2004
    Location
    Louvain-La-Neuve, Belgium
    Posts
    11

    Default Setting locales in jstl views

    Hello,

    I have a problem with the locale resolver and the locale change interceptor in my jstl views: even though resource bundles are picked up correctly, the request locale (as specified by ${pageContext.request.locale.language}) is not modified.

    I need to retrieve the locale because I need to resolve messages coming from database (stored in a map) based on user's language.

    Is there a way to have these parameters set ? If not, how can I access the spring modified locale in a standard way ?

    Thanks in advance.

    Julien

  2. #2
    Join Date
    Aug 2004
    Location
    Amsterdam, Netherlands
    Posts
    450

    Default

    The locale should be set correctly AFAIK.

    Apart from the context, it's also bound to the request under the key defined in the Config class from the Servlet spec:

    javax.servlet.jsp.jstl.core.Config.FMT_LOCALE

    I don't know the exact String value of the constant.

    Have a look if the Locale bound to the specified key is the correct one. If not, could you check back here and let me know?

    rgds,
    alef
    Alef Arendsen
    SpringSource
    http://www.springsource.com

  3. #3
    Join Date
    Aug 2004
    Location
    Amsterdam, Netherlands
    Posts
    450

    Default

    By the way, what server are you using?
    Alef Arendsen
    SpringSource
    http://www.springsource.com

Similar Threads

  1. Context initialization failed
    By kanonmicke in forum Container
    Replies: 7
    Last Post: Sep 29th, 2005, 12:35 AM
  2. Load JSTL views from outside the web-app
    By MattiasR in forum Web
    Replies: 2
    Last Post: Aug 15th, 2005, 05:17 AM
  3. Spring/Hibernate Delete/Update Problem
    By Noname in forum Data
    Replies: 4
    Last Post: Jun 15th, 2005, 11:07 PM
  4. Replies: 2
    Last Post: May 13th, 2005, 05:42 AM
  5. Transaction Management
    By caverns in forum Data
    Replies: 3
    Last Post: Mar 8th, 2005, 06:38 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •