2

I am using this call to get the userlanguages of a browser in asp.net

HttpContext.Current.Request.UserLanguages

It worked fine for years, but now this request is always null on Internet Explorer and Microsoft Edge. It still works on other browsers like Google Chrome, Firefox..

Any solutions?

Tommehh
  • 872
  • 1
  • 17
  • 44
  • Try setting UICulture and Culture on the page directive and what is the result of HttpContext.Current.Request.UserLanguages in google chrome?. – Hameed Syed Dec 14 '16 at 09:01
  • i tried the same in php http://www.alphamedia.co.at/Test/ there you see the results – Tommehh Dec 14 '16 at 14:26
  • en-US,en;q=0.8 is the result from the above link.Looks you have got the result. Didn't you? – Hameed Syed Dec 15 '16 at 12:09
  • on chrome i get "de-DE,de;q=0.8,en-US;q=0.6,en;q=0.4,es;q=0.2,fr;q=0.2,af;q=0.2", in internet explorer it's empty – Tommehh Dec 15 '16 at 12:39
  • Have a look at it ,it may help.http://stackoverflow.com/questions/1790457/global-asax-get-the-server-name – Hameed Syed Dec 15 '16 at 12:44

0 Answers0