• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 303
  • Last Modified:

Globalization not workin in production

We currently have globlization set up and are able to switch between multiple languages on our development box.  However when we push the code to production it stays defaulted to en-US.  I have verified all entries in the web-config  are the same and database entries for setting the session variables are the same.  

When I output my session variable to the page is it correct for the change language.  But the
CurrentUICulture stay en-US  

Are there any server permissions or other factors that would affect this?  

Any help is appreciated.

      <add name="CookieLocalizationModule" type="PDR.CookieLocalizationModule, PDR" />
<identity impersonate="true" />  
 <globalization uiCulture="auto" culture="auto" />

public void PreRequestHandlerExecute(object sender, EventArgs e)
            string lang = null;
            PDR.Models.Currency currency = null;
            string currencyCulture = null;
                lang = HttpContext.Current.Session["Language"].ToString();
                currency = (PDR.Models.Currency)(HttpContext.Current.Session["Currency"]);
                currencyCulture = currency.CurrencyCulture;
                var culture = new System.Globalization.CultureInfo(lang);
                var cculture = new System.Globalization.CultureInfo(currencyCulture);
                Thread.CurrentThread.CurrentCulture = cculture;
                Thread.CurrentThread.12= culture;
            { }
  • 2
1 Solution
deepu chandranCommented:

Two major Possiblities for this,
1) Check your resource DLL's are properly Created
2) The resource name and the language variable string should match
lang = HttpContext.Current.Session["Language"].ToString();
This should be "en-US" ,"de-DE" etc

Josh_BladeAuthor Commented:
At the end of the day my issue ended up being an application pool setting in IIS.  

It was not loading the Http Module when set to integrated security. It has to be set to classic.


Thanks for the help.
Josh_BladeAuthor Commented:
Hope this helps someone else.
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now