Template:Translatable template name/doc

    HelpClose
    If you encounter any technical issues as you edit, please report them.
    3 noticesClose

    Warning: You are not logged in. Your IP address will be publicly visible if you make any edits. Read the Privacy Policy to learn what information we collect about you and how we use it.

    If you log in or create an account, your edits will be attributed to your username, along with other benefits.

    You do not have permission to edit this page, for the following reason:

    Your username or IP address has been blocked.

    The block was made by ‪Amazingakita‬. The reason given is Spamming links to external sites.

    • Start of block: 21:29, 1 April 2025
    • Expiration of block: 21:29, 1 May 2025
    • Intended blockee: 100.101.254.78

    You can contact ‪Amazingakita‬ or another administrator to discuss the block. You can use the "Email this user" feature if a valid email address is specified in your preferences and you have not been blocked from using it. Your current IP address is 100.101.254.78, and the block ID is #232. Please include all above details in any queries you make.

    You are using a browser which is not officially supported by this editor.

    From Nonbinary Wiki
    VisualEditor - Icon - Advanced - white.svg This is a documentation subpage for Template:Translatable template name.
    It contains usage information, categories and other content that is not part of the original page.

    Purpose[edit source]

    This template is used to return the name of translatable templates in the language of the current page. Templates, like all other MediaWiki pages, can be translated using the Translate extension, which creates subpages with the form "pagename/language code". The template first checks if the name of the page contains a language code. If it does, it then checks if the template name given as a first parameter has a translation in that language. If the page name does not contain a language code, or if the navigation template doesn't exist in that language, it will display the English template.

    How to use[edit source]

    • {{ {{Translatable template name|name of navigation template}}|parameters....}}
    • {{ {{TNTN|name of navigation template}}|parameters....}}
    • {{ {{tntn|name of navigation template}}|parameters....}}

    Parameters[edit source]

    The current version of the template may now include any kind of named or numbered parameters, whose values will be transferred into the called template (with the exception of parameter 1 containing the basename of the translatable template to transclude). Numbered parameters will be shifted down by one position, all named parameters will be passed unchanged.

    One named parameter is treated specially:

    • {{Translatable template name|namespace=:somename:|page name}}
    • {{TNTN|namespace=:somename:|page name}}
    • {{tntn|namespace=:somename:|page name}}

    This namespace will be used to specify another namespace from which the translatable pagename will be transcluded, instead of referencing the page name from the default :Template: namespace. Note that this parameter is also passed (without modification) within the parameters of the transclusion.

    Dependency[edit source]

    See also[edit source]


    == Purpose ==

    This template is used to return the name of translatable templates in the language of the current page. Templates, like all other MediaWiki pages, can be translated using the [[mw:Extension:Translate|Translate extension]], which creates subpages with the form "pagename/language code". The template first checks if the name of the page contains a language code. If it does, it then checks if the template name given as a first parameter has a translation in that language. If the page name does not contain a language code, or if the navigation template doesn't exist in that language, it will display the English template.