A wiki can be set up to include different language versions of a wiki content. Wiki administrators have to make some decisions regarding how they want to support their wiki users' language in addition to simply providing translated content.
The following considerations refer to a single-wiki scenario and don't apply if the language versions are maintained in multiple wikis.
Concepts
To make a wiki multilingual, the following steps are suggested:
- Import a language switcher
- Create wiki pages with linked translation subpages
- Set multilingual navigation
- Create page lists from language versions
The following information gives some suggestions how to organise a wiki around its multilingual content. It does not consider using the MediaWiki extension Translate which is often installed in multlingual wikis to faciliate a section-by-section translation of wiki pages. If most of your wiki content needs consistently accurate translations, this extension can be useful.
Language switcher
To show that a page has different versions, it is useful to indicate this with a language switcher on each page. If you have no language switcher in your wiki, you can download a language switcher template. Be sure to read the configuration instructions on the downloads page. You need to adjust the languages you want to support in the template.
Wiki pages with linked language subpages
Let's take a page called Dress code and create a German language version as a subpage. After saving the page Dress code/de with its translated content, it looks like this:
Now, we have the German translation that we wanted. It is always shown in the context of the user language preferences of each user. This means that the user interface elements do not necessarily correspond to the translated language. But since the user decided on this language preference, it does not negatively effect the user.
Another point to consider is that the page title is shown as "de", which is not always what we want. To provide a meaningful title, we need to set it in the page options, under the Advanced Settings:
The search engine will index this display title so that the title search returns the expected result.
Adding the language switcher to a page
To add the language switcher to a page:
- Open the page in edit mode.
- Insert the template Languages form the editor toolbar.
- Enter a display title for the page (recommended for subpages).
Linking translated pages
Now that we have a page with a language version, the user interface should indicate right away that a page has a translated version. This is best done with a language switcher template. Alternatively, you can also set up interwikilinks for this purpose. Let's compare the two options.
Language switcher
To show directly on a page whether language versions exist, a template needs to be included in the content area of each individual page. It creates a switcher that allows to "jump" between the pages.
A starting template to import into a wiki can be downloaded from the downloads page. For the template to work correctly, the template needs to be set to the specific content language of your wiki.
Interwikilinks
Another possible solution is to use interwikilinks to switch between the languages. In that case, the language switcher is automatically created in the top toolbar of the wiki, when a page contains interwikilinks.
Namespaces: This setup assumes that you always have the same main language as a starting point for your translation. If this is not the case, you can also think about using namespaces for your different language versions. This makes sense when you have content in different languages, but the content in these languages is not necessarily always related. You could create namespaces for your languages as you see fit, e.g. DE:
, FR:
or IT-de:
, IT-fr:
and so on. If there are related pages between languages, they can be connected through interwikilinks.