Template:Template translation

From PZwiki
Lock-locked.png
This page has been put into protection by a PZwiki administrator.
Reason: This template is considered High Risk as it appears on multiple pages.
Only users in the sysop user group may edit this page.
Notebook.pngTemplate Documentation

This template is used for templates which need to be translated into other languages.

LightBulbYellow.png
Do not add this template to templates end with a language code. This template is only for English templates. If you want to translate the template, please follow the instructions on the corresponding template's documentation.

Usage

You can add {{Template translation}} (shortened as {{tt}}) to the position where the translated text should be placed. The template will then check if the translated template exists and if so, it will be included. If not, the default text will be shown.

LightBulbBlue.png
This template should only be used in the template namespace.

Parameters

name Required
The name of the template to be translated. Usually should be the name of the template itself.
default Required
The default text to be shown if the translation does not exist.
arg1 - arg3
Arguments to be passed to the translated template. This can be useful if the template has more than one text to be translated. Then you can pass arg1 to identify which text should be translated.

Syntax

{{tt|name = template name
| default = default text
| arg1 = arg1
| ...
}}

How to translate

This template doesn't need to/shouldn't be translated, but you can translate the documentation of this template with the following steps:

  1. Create a subpage of this template with the language code of the language you want to translate to.
  2. Copy the code wrapped in the <noinclude> tag in this template into the page you created.
    {{Translation guide}} template should be removed from the translated documentation.
  3. Translate the page according to the translation requirements of normal pages.

See also

Editors can experiment in this template's sandbox.