Template:Msg-meta

From translatewiki.net
Jump to navigation Jump to search

1

Test Template Info-Icon - Version (2).svg
The documentation of this template is included from its /doc subpage. [Edit]

This is a meta template for {{Msg}} template families.

Syntax:
{{Msg-meta
|meta= suffix of the "Msg-*" template page name
|class= custom class name
|namespace= namespace for target messages
|1= {{{1<noinclude>|Example-message-ID</noinclude>}}}
|2= {{{2|}}}
|notext= {{{notext|}}}
|exist= {{{exist|}}}
|lang= {{{lang|}}}
}}
Parameters:
  • |meta= last part of the template name appended after "Template:Mw-".
  • |class= do customise per template. Typically same as the template name (e.g. msg-freecol).
  • |namespace= namespace which the msg template targets.
  • |1= (pass through) message ID (should exist inside the indicated namespace, required parameter).
  • |2= (pass through) optional comment.
  • |notext= (pass through) whether or not to show the localised message text. Any non-empty value will drop this display (after the message id and the optional comment). Should be empty by default.
  • |exist= (pass through) whether or not to test the existence for the message (and track it in a subcategory of Category:Message maintenance). Should be empty by default to enable this maintenance, however some message documentation subpages populated with lot of messages may no longer work. If this parameter is explicitly set to a non-empty value, no check of existence will be made (assuming that the message really exists), and this can be used (on common messages such as those of Mediawiki Core) to reduce the number of "costly parser function calls" (to code>#ifexist:: it is limited to 100 tests per viewed page) in order to preserve the check for messages listed at end of a list of messages.
  • |lang= (pass through) specifies the language of the translated message to display, instead of {{RelevantLanguage}} by default.
Examples:
{{Msg-meta
|meta= fudforum
|class= msg-fudforum
|namespace= FUDforum
|1= {{{1<noinclude>|Locked</noinclude>}}}
|2= {{{2|}}}
|notext= {{{notext|}}}
|exist= {{{exist|}}}
|lang= {{{lang|}}}
}}


See also: