Search code examples
asp.netjsonglobalizationresxihttphandler

Localization in javascript via IHttpHandlers


What's the best way to acces .resx files in a Http Handler in ASP.NET?

I need to access them in javascript. My goal is to serialize them in JSON via a IHttpHandler. The problem is that I simply can't figure out which .resx I should load according to request language.

Thanks!


Solution

  • you can use GetGlobaResourceObject or GetLocalResourceObject as here

    http://msdn.microsoft.com/en-us/library/ms227982.aspx