Locale overrides by cookies
An administrator or web developer might want to provide end-users a means of overriding browser language preferences temporarily by setting cookies, such as creating a company web portal link for users to click instead of manually changing their browser options.
By default, the PingFederate localization framework supports overriding the locale using a cookie named pf-accept-language
. The cookie value must conform to the guidelines defined under IETF BCP 47. For more information about the Java core method that PingFederate uses to parse the cookie, see Locale.forLanguageTag(String languageTag).
This locale-override behavior is the default implementation of the Java interface, LocaleOverrideService
, defined in the PingFederate SDK. For more information, see the Javadoc for that interface in the <pf_install>/pingfederate/sdk/doc
directory.
PingFederate displays the language indicated in the cookie if the language is supported in the language-packs
directory. If the matching localization file is not found, PingFederate defaults to the browser settings.