Creating and using multilingual string tokens

String tokens in Platform can support multiple languages. You can use multilingual string tokens to localize display text generated by your code. See Creating and using string tokens for more information about string tokens.

Every string token you create is available to any application in the tenant. You must attach a string token to any application that uses it before publishing or exporting the application. See Attaching string tokens for details.

Suppose a tenant is configured to support three languages: English (base language), German (additional language) and French (additional language). The following example shows how a multilingual string token works in an HTML component on a page.

When you create a string token, the New String Token dialog contains a field for each language supported by the tenant. Enter the string token value for each supported language and a Token Name. The following screen shows an example string token that evaluates to a welcome message for the Lending Library application:

New String Token

The following screen shows an HTML component that uses the string token:

String Token in HTML Component

Platform will render the above HTML component based on the user's language setting. The screens below show the resulting text when the user's language is set to English and when the user's language is set to German:

Welcome Message English

Welcome Message German