Documentation > UCP Implementation Guide > Testing

Language/Translation Testing

By default, the UCP scripts will pull the users configured language from their browser settings and use that to show to correct translations. There are several ways to test the different languages, so we’ll provide some context and start with an overview of how the translations on your notices function.

In Step 1 of notice configuration, you’ll select the translations to support (here, translations are equivalent to a specific language).   When you add translations to your notice, the first one you add is the default language (this can be changed by highlighting the translation and clicking the Set Default marker).  When the scripts execute, they will pull the browser language settings, look for a match in the notice translations, and use the default if a match isn’t found.  For example, if you always want to show German no matter what country the user is from, only add German translations to the notice.  If you want to show French and Spanish to users who speak those languages and English to everyone else, add English as the default translation and the French and Spanish translations to the notice.

Changing the Browser Language Settings

The best way to test the different languages is to change your browser’s locale settings.  Some browsers make this easier than other browsers.  Currently the Evidon team does this testing primarily with Firefox and Opera, both of which make it easy to switch languages on the fly.

Javascript Language Override

If you need to force a language through script you can do that by using the UCP JavaScript API.  Please review the API documentation for details.

Connect with Crownpeak