Localizing your site
Enterprise publishers often make their assets available in multiple languages. For example, a publisher with visitors in England, Spain, Germany, and Korea publishes all its assets in all four languages. To give visitors a seamless multi-lingual experience, you need to localize your site.
Web pages contain two forms of text: dynamic and static. Dynamic text changes with each asset a visitor views, and static text remains the same regardless of the asset.
Referring to the previous illustration, the headline is dynamic—it changes when the visitor clicks on a link to view a different asset. The words Tags
, Share
, and Integrations
are static—they remain the same regardless of the asset a visitor is reading.
Localizing a site is the process of providing the static text in a different language. For example, localizing a site for Spanish requires providing translations for the terms Tags
, Share
, and Integrations
. (In contrast, providing dynamic text in different languages requires translating assets from one language to another.)
Strategies for delivering translated and localized content
Typically, there are two strategies for delivering translated and localized content:
- Place the translated site in a separate directory under the top-level directory.
- Place the translated site in its own domain.
The following table provides examples of each strategy.
Asset | English (en) | Spanish (es) | French (fr) |
Homepage | example.com/ | example.com/es/ | example.fr/ |
About us | example.com/about-us | example.com/es/quiénes-somos | (Not translated) |
Contact us | example.com/contact | example.com/es/contáctenos | example.fr/contacter |
Terms and conditions | example.com/terms | example.com/es/términos | example.fr/conditions-générales |
Referring to the above table, there are two scenarios for delivering translated content. In the first scenario, all the Spanish translations are stored under an /es
directory in the same domain as the English site. In the second scenario, all the French translations are accessed from a different domain example.fr
. The first scenario requires adding a Spanish localization to the English site; the second scenario does not require adding a localization, as the entire site is in French.
How Brightspot delivers localized text
When delivering a web page to a browser, Brightspot sends the dynamic text as well as the static text (see illustration, above). For example, when a visitor requests a URL example.com/es/términos
, Brightspot sends the translated Spanish dynamic text for example.com/terms
. In addition, Brightspot determines the language of the required localized static text using one of the following methods:
- Using a query parameter—Brightspot provides localized text corresponding to the value of a query parameter
lang
. - Using the asset's locale—If the visitor requested
example.com/es/términos
, and the assettérminos
has a Spanish locale, then Brightspot knows to deliver the localized Spanish static text. (Some sites provide a link, such asLeer en español
, to render the current asset in Spanish.) - Using the site's locale—If the visitor requested
example.fr/conditions-générales
, and the siteexample.fr
has a locale of fr-FR, then Brightspot knows to deliver the localized French static text. (Some websites provide a icon so visitors can view the entire site in a different language.) - Using a default language—Every Brightspot server is configured with a default locale, typically US English. If you don't make a configuration at the site, content, or query-parameter level, Brightspot delivers the localized static text in the corresponding language.
Steps for providing localized text
The following steps are required to deploy localized text:
- Add static text for each locale (see Configuring localized static text).
- Configure the delivery mechanism for localized text (see Configuring localization delivery).
- Optional:
- Configuring the locale for each asset (see Configuring an asset's locale).
- Configuring the locale for an entire site (Configuring a site's locale).
When localization is not necessary
Not every website requires localization. If your entire web site is delivered in a single locale, then there is no need to localize the static text.