Till now, we created pages in the en
(English) language, which is the default language in Sitecore. Sitecore supports all the languages or cultures that are supported by the .NET framework.
In this recipe, we will create content pages in multiple languages (English, Spanish, and Italian) and create a language switcher component to switch and view pages in these languages.
Sitecore by default contains the en
(English) language. We will first create es-ES
(Spanish) and it-IT
(Italian) languages:
From the Content Editor, select the
/sitecore/system/Languages
item. Add a new language, Spanish, as shown in the following image. Similarly, create the Italian language as well:Now, from the Content Editor, select any content item on the right-hand side pane. You will find a language drop-down menu; clicking on this will display all the languages created in Sitecore, as shown in the following image:
Select Spanish from this drop-down; it will navigate to...