You are designing an ASP.NET Web application.
Each page of the Web application will have a common master page and derive from a common base page class. You have the following requirements:
– Support multiple languages for user interface labels.
– Enable automatic detection of language based on browser language settings.
You need to recommend an approach to support localization.
What should you recommend?
A.
In the Web.config file, add a globalization element with the uiCulture attribute set to auto.
B.
In the Web.config file, add a globalization element with the responseEncoding attribute set to auto.
C.
In the code-behind for the master page, override the OnInit() method.
Set the Thread.CurrentThread.CurrentUICulture property based on the value of the Request.Browser.Capabilities[“preferredLanguage”] dictionary entry.
D.
In the code-behind for the base page, override the InitializeCulture() method.
Set the Thread.CurrentThread.CurrentUICulture property based on the value of the ViewState[“Accept-Language”] dictionary entry.
Explanation:
To have ASP.NET set the UI culture and culture to the first language that is specified in the current browser settings, set UICulture and Culture to auto
http://msdn.microsoft.com/en-us/library/bz9tc508.aspx