Getting started

Adding language versions

Last updated: 18/8/2020

Table of contents

1. What are language versions?

Sitecore supports multiple different language versions for pages. By default, all pages should be created in English - when you add a page it's important that you do so using English. However, where language versions are added to pages, users are able to select that version of the page - and will be presented with an alternative version in the chosen language.

The screenshot below shows an example of a page that has been translated into both English and Japanese (See the example). You can tell a page has a translation available by the presence of the button in the top right hand corner of the banner image. Clicking this will highlight the versions available.

Notice how after switching to the Japanese version, the URL changes - to include reference to the language in question.

Image
Fig 1: English (default) version of a page

 

Image
Fig 2: Japanese version of the same page in fig 1 above. Notice that url now contains reference to the language version 'ja-jp'

At present, it is possible to add the following language versions to a page:

  • Chinese (simplified and traditional)
  • Danish
  • Dutch
  • French Canadian
  • German
  • Japanese
  • Korean
  • Polish
  • Portuguese
  • Romanian
  • Russian
  • Spanish
  • Turkish
  • Vietnamese

2. Creating new language versions

When you create a page and wish to add an alternative language version you will need to take four key steps:

  1. Create the document (i.e. a project) in the CMS - entering content in English
  2. Create and add all necessary modules to your page - entering content in English
  3. Create the language version of your project
  4. Create the language version of each of your modules

This guide outlines how to complete steps 3 and 4 and assumes you've already created your page and modules in English. For advice on this, please browse the online guide.

This guide uses the example of adding a language to a project already created in English.

Adding language versions to a document

Once you have created your project (or other content type) in English, please following the following steps:

  • Browse to your content item in the CMS - click on your content item so that it is selected and the content is editable
  • Towards the top right of the screen you will see an option for languages - by default it will have 'English' highlighted
  • Click this - and a drop down menu of available languages will appear - click on the language you wish to add
Image
Fig 3: Click 'English' and choose your language from the dropdown menu
  • After selecting your language, the page will re-load. You will then see a warning at the top of the page that 'No version exists in the current language. You need to click 'Add a new version'
Image
Fig 4: Click 'Add a new version' to create your new language version
  • After clicking 'Add a new version' the page will reload in the CMS, and you will now be able to edit the various fields. The English version will likely be in place - you need to replace each field that contains English with the relevant translation
  • You do NOT need to re-add content such as:
    • Image
    • Related content
    • Location
    • Contact
  • You do need to re-add content including:
    • Title
    • Name
    • Summary
    • Metadata - it is vital that you add a new 'meta title' to prevent duplication
  • Save the document once you have edited all the relevant fields
Image
Fig 5: The new version has been created and the language (Spanish) has replaced the default English

Adding a language version to a module

The process for adding language versions to modules is identical to that used for documents.

You will need to:

  • Select the module you wish to translate
  • Click the language menu (as shown above) and choose your language version
  • Click 'Add a new version' once the module has reloaded
  • Add all relevant content in your new language
  • Save the module and repeat for each additional module you wish to translate

3. The Experience Editor

Once you have created language versions of your page and relevant modules, please note that you will then have to rebuild the page via the Experience Editor - this is the point at which you add the modules to your page and select their ordering.

Please note - it is very important that you launch the Experience Editor from your new language version - for example, above we have created a Spanish version of the project. To edit this version in the Experience Editor, it must be selected - then click 'Experience Editor' as shown below.

When in either the CMS or the Experience Editor you can swap between the language versions i.e. English and your new version at any time.

Image
Fig 6: You must re-add the modules to your new language version. Ensure it's selected (in this example 'Spanish') and then launch the Experience Editor

FAQ

  1. Can I add multiple languages to a single document or module?
  2. Why do I have to rebuild the page in the Experience Editor?
  3. Do I have to translate and re-add all the modules from my English version?
  4. Why do I have to create an English version - my audience isnt located in the UK?

1. Can I add multiple languages to a single document or module?

A. Yes. Any page can have multiple different language versions available. You must simply repeat the steps above for each individual language that you wish to add.

2. Why do I have to rebuild the page in the Experience Editor?

A. Each individual language represents a version of the page. Versions allow you to completely recreate a page in a different way. Because of this, it is necessary to completely rebuild the new language version.

3. Do I have to translate and re-add all the modules from my English version?

No. You can add as many or as few modules as you wish to your new language version. You can also create modules just for your language version - just remember that you need to create them in English first. NB - this doesnt mean that you have to add English content, if the module will only be used on the foreign language version.

4. Why do I have to create an English version - my audience isn't located in the UK?

By default, arup.com is designed to serve content in English. This means that the first page a user sees will be in English. At present, the site is not able to serve content in a local language by default. It is therefore necessary to ensure that every page is first served in English to ensure consistency.