How can I translate text from the source code of my help center?

Question

What steps can I follow to translate text from the source code of my help center?

Answer

You can use dynamic content to translate text from your help center. Follow the steps below:

Enable your locale

Note: The language variant must match your help center variant. Otherwise, the text won't be dynamically translated. For example, if your help center is in English (US), then you must enable the English (United States) locale. English (United Kingdom) won't match.

Create your dynamic content > Generate the language variants for each language you will display

Copy the placeholder from your dynamic content, which starts with {{dc.

You can search for the dynamic content using the title of the content or the placeholder.

Open the code of your help center

Replace the text you want to translate with the dynamic content placeholder from the step above

Reformat the placeholder, for example, instead of: {{dc.example_dynamic_content}}, use this format: {{dc 'example_dynamic_content'}}

Publish your changes