Multiple choice technology web technology

Which session parameter is used to identify the application locale info in Struts 1.2?

  1. Globals.LOCALE_ID

  2. Commons.LOCALE_ID

  3. Globals.LOCALE_KEY

  4. Constants.LOCALE_KEY

Reveal answer Fill a bubble to check yourself
C Correct answer
Explanation

In Struts 1.2, the locale information is stored in session with the key Globals.LOCALE_KEY. The constant value is "org.apache.struts.action.LOCALE". This locale is automatically set by Struts based on the user's browser preferences or can be manually set. Option A uses ID instead of KEY which is incorrect. Option B incorrectly uses Commons prefix. Option D incorrectly uses Constants prefix.