Tutorial:Adding new language

This tutorial describes how to add a language to the ones already supported, at the level of the whole Statistics Explained website. When a language has been added, it is presented as a clickable link at the bottom left of all pages available in that language, and navigation labels are shown in that language (unless logged in: then everything is in English!).

At present Statistics Explained accommodates 23 language versions (language code between brackets): English (en), the 'mother' version, and in alphabetical order: Bulgarian (bg), Croatian (hr), Czech (cs), Danish (da), Dutch (nl), Estonian (et), Finnish (fi), French (fr), German (de), Greek (el), Hungarian (hu), Italian (it), Latvian (lv), Lithuanian (lt), Polish (pl), Portuguese (pt), Romanian (ro), Russian (ru), Slovak (sk), Slovenian (sl), Spanish (es) and Swedish (sv).

Display and navigation

On any page within Statistics Explained only the available language versions for that particular page are shown, at the bottom of the navigation area on the left, below 'In other languages'; the current language version (often only English) is in black, the other one(s) available are in clickable blue.

Adding a language

The new language code has to be added in the template Template:LanguageBar (and in some particular cases also in Template:LanguageBarUser):

{{LanguageBar/Lang|xx|{{{1|}}}}}
(with xx=language code of language to be added - see list of language codes, note: language codes are often similar to country codes, with some notable exceptions however: cs, da, et, sl, sv).
at the appropriate alphabetical position (for convenience, not necessity).

For instance

*[[:{{{1|:{{NAMESPACE}}:{{BASEPAGENAME}}}}}|English]]

{{LanguageBar/Lang|bg|{{{1|}}}}}{{LanguageBar/Lang|xx|{{{1|}}}}}{{LanguageBar/Lang|cs|{{{1|}}}}}