Skip to main content

Show your directory in other languages

Translate your partner directory into other languages (localization) with machine or interface-only translation, one address per language.

M
Written by Mario Tarabbia

Translations show your public directory in other languages, with each language at its own address, such as partners.yourdomain.com/fr/. PartnerPage support sets up the languages for your directory. This article is for vendors.

Who can do this: PartnerPage support sets up translations; Admins add language links in Branding and layout · Availability: available on request: contact PartnerPage support to turn it on

How translations work

Translations apply to your public directory: the directory page, partner profiles and the visitor forms. Each language you choose gets its own address. One language is the default, usually with no language code in its address. When you ask support to turn on translations, tell them:

  • Which languages you want, and which one is the default.

  • How the language should appear in the address: as a path, such as /fr/, or as a parameter, such as ?lang=fr. You can pick the code for each language, such as fr or fra.

  • Which translation mode you want: machine translation or interface-only, both explained in this article.

Language in the address

The language of a page comes from its address, in one of two styles:

Style

Example addresses (default English, plus French)

Path

partners.yourdomain.com/ and partners.yourdomain.com/fr/

Parameter

partners.yourdomain.com/ and partners.yourdomain.com/?lang=fr

With a parameter, an address with an unknown code shows the default language. Each page tells search engines about its other language versions, so they can show visitors the right one.

Machine translation of everything

Machine translation is the standard mode. Machine translation translates the whole page, including partner profiles, filter names and options, and the text in your page sections, using Google's website translator in the visitor's browser. PartnerPage tells the translator that the page is in English, so write your directory content in English. Machine translation works for any language Google's translator supports.

Interface-only translation

Interface-only translation changes PartnerPage's own interface text, such as buttons, the search box, Sort by and form messages, into the visitor's language. Content stays as it was written: partner profiles, filter names and options, and the text you set in Customizations > Branding and layout. Use interface-only translation when partners write their profiles in the local language themselves.

Interface-only translation covers these 21 languages: Chinese (Simplified), Chinese (Traditional), Czech, Dutch, English, Finnish, French, German, Hindi, Hungarian, Indonesian, Italian, Japanese, Korean, Polish, Portuguese (Brazil), Romanian, Russian, Spanish, Swedish and Ukrainian. Other languages show the interface in English.

Let visitors switch language

Your directory has no built-in language switcher. Visitors reach a language through its address, so link to each language yourself:

  • Add a button per language to your directory's navigation bar, or a link per language to the footer, in Customizations > Branding and layout > Layout. See Change page layouts and sections.

  • Link to the language addresses from your own website.

Use window.i18n in custom code

When translations are on, your directory's custom scripts and code sections can use window.i18n, for example to build your own language menu:

Function

What it does

window.i18n.getLocales()

Lists the directory's language codes.

window.i18n.getLocale()

Returns the language code of the current page.

window.i18n.setLocale('fr')

Switches the page to that language.

window.i18n.getLocalePath()

Returns the current language's path code. Path style only.

window.i18n is null when translations are off. Add scripts in Customizations > CSS and JS: see Add custom CSS and scripts.

Common questions

Are partner profiles translated?

Partner profiles are translated with machine translation, which translates the whole page. With interface-only translation, profiles stay in the language the partner wrote them in.

Does translation work with my custom domain or reverse proxy?

Translation works with a custom domain and with a reverse proxy. With the path style behind a reverse proxy, the language code comes before your directory's path, such as yourdomain.com/fr/partners/, so your proxy must also forward those addresses to PartnerPage.

Did this answer your question?