Last modified on 19 July 2011, at 19:50

Template:MWheader

Namespace-mediawiki.svg Template:MWheader forms part of the MediaWiki interface and can only be edited by administrators.
To request a change to Template:MWheader, add {{Edit request}} to this talk page, followed by a description of your request.
This interface message or skin may be documented on MediaWiki.org or TranslateWiki.
Documentation icon Documentation[view] [edit] [history] [purge]

This documentation is transcluded from Template:MWheader/doc.


Goes at the top of MediaWiki talk pages. It has several optional features. Some of these can be either the parameter name or as an unnamed parameter value. The order doesn't matter.

  • To add a bunch of interwiki links, use {{MWheader|iw}}, which creates:
Namespace-mediawiki.svg Template:MWheader forms part of the MediaWiki interface and can only be edited by administrators.
To request a change to Template:MWheader, add {{Edit request}} to this talk page, followed by a description of your request.
This interface message or skin may be documented on MediaWiki.org or TranslateWiki.
Parameter value As parameter name What it does Notes
- description=description adds a description box -
subpages subpages=base page links to all existing subpages and sub-talkpages (collapsible) the root[1] page name is the default (example)
lang links lang links=base page creates a box of links to translations the base page name is the default; unlike subpages, this only lists pages matching a known language code (example)
lang links lang links=0 turns off the box of links to translations, which is shown by default
talk links [inherits from lang links] use with lang links to also list any talk pages usually not useful, unless some exist with actual discussion and not just old translations
- keyword=subpage suffix use with lang links to add a "suffix" to the links for special cases where the subpages follow a different naming convention[2] (example)
- doc=pagename or doc=no adds/changes/overrides a message about a documentation page this only needs to be entered manually if the doc page is not the expected subpage.[3] (example)
- mw-link=page changes the link to MediaWiki's manual page page refers to the full pagename, don't include the interwiki prefix ("mw:")
iw - creates links to 150+ other Wikimedia projects see example above
js - adds a message about Commons:Javascript styleguide replaces {{JS styleguide}} (example)
selectskin - inserts {{selectskin}} -
msg msg=title allows you to create a collapsed table of related system messages uses {{msgx}} (partial example)
- m1, m2,...m6=pagename shows the pagename as one of the "related system messages" for use with msg
gadget - adds page to Category:Gadget scripts These last two simply categorize the page.
user script - adds page to Category:User scripts It's usually better to categorize this way on talk pages where categories tend to get removed or archived.

NotesEdit

  1. This means {{#titleparts:{{PAGENAME}}|1}}, not {{BASEPAGENAME}}, so sometimes this will list a lot more pages than you want. In that case, set it equal to the desired base page or use lang links.
  2. For example, the German (de) translation of MediaWiki:Uploadtext/ownwork is MediaWiki:Uploadtext/deownwork, so ownwork is the keyword. If not set, it will look for something ending in "/de".
  3. In the MediaWiki namespace, documentation pages were titled "/Documentation" (not "/doc"), and some still are, so this is what it looks for, however many now reside in the Help namespace. Language link subpages are titled "/lang" (same as templates).

LocalisationEdit

This template is autotranslated a little differently than others. Only the text is switched out based on the user's interface, not the whole template. Please translate the following and add it to a subpage of Template:MWheader/text, e.g. Template:MWheader/text/en.

{{#switch:{{{1}}}
|maintext = '''The page forms part of the [[mw:Manual:System message|MediaWiki interface]] and can only be edited by [[Commons:Administrators|administrators]].'''<br />To request a change to the page, add {{tl|editprotected}} to this page, followed by a description of your request.
|extdoctext= This interface message or skin may {{#if:{{{also|}}}|also}} be documented on [[mw:{{{mw-link}}}|MediaWiki.org]] or [[translatewiki:MediaWiki:{{BASEPAGENAME}}/qqq|translatewiki.net]].
|doctext = '''Documentation''' on this script is at '''[[{{{doc}}}]]'''.
|jstext = When editing this script please adhere to the [[Commons:Javascript styleguide]].
|relatedtext = Related system messages
|subpagestext = List all subpages of {{{subpages}}} and {{TALKPAGENAME:{{{subpages}}}}}
|subpagestext2 = Talk subpages
|paramtext=Parameters
}}<noinclude>
{{translated tag|localisation}}
</noinclude>
There is no /lang page or /layout page to deal with. Keep in mind this is still a work in progress and new text fields may be added in the future.