Template:W/doc
- TemplateData
TemplateData is a way to store information about template parameters (the description of those and of the whole template) for both humans and machines. It is used by VisualEditor and possibly other tools like Upload Wizard.
Existing template documentation
At Wikimedia Commons, it is recommended to use {{TemplateBox}} with either useTemplateData=1
or useTemplateData=only
on the /doc
subpage and transcluding it with {{Documentation}} into the template. <nowiki>
-tags can be wrapped around the arguments, if required, to avoid templates being expanded.
Newly created template documentation and imports
Another option, especially for imported templates, or for users with JSON experience, is placing raw <templatedata>-tags into the Wikitext of the template, as described in various Wikipediae.
Wikipedia's help about TemplateData • Commons-specific information
Recommendation
Instead of an external link to sister projects e.g. [http://en.wikipedia.org en.wikipedia] use better an internal one like {{W||en.wikipedia}}.
Examples
- All parameter combinations
000 {{W}} → Template:W/doc [1]
003 {{W|3=es}} → Template:W/doc [1] Template:F {{We}}: Template:Tle → Template:We
003 {{W|3=pt}} → Template:W/doc [1]
020 {{W||Main Page}} → Page
020 {{W||en:Main Page}} → Page
023 {{W||Ĉefpaĝo|eo}} → [1]
023 {{W||pt:Wikipedia|pt}} → [2] Template:F {{Wp}}: Template:Tle → Template:W/doc
023 {{W||pt:Wp|pt}} → [3] (preferred style of a link to a national mainpage)
023 {{W||de:Wp|de}} → [4] Template:F {{Wd}}: Template:Tle → de:Wp
100 {{W|Page name}} → Page name
103 {{W|Page name||it}} → Page name Template:F {{Wi}}: Template:Tle → Template:Wi
103 {{W|Page name||fr}} → Page name Template:F {{Wf}}: Template:Tle →
Template:Wikify is deprecated. Please use a more specific cleanup template as listed in the documentation. |
103 {{W|{{FULLPAGENAME}}|3=pl}} → Template:W/doc
120 {{W|Page name|Display name}} → Display name
123 {{W|Page name|Display name|nl}} → Display name Template:F {{Wn}}: Template:Tle → Template:Wn
123 {{W|Page name|Display name|hu}} → Display name Template:F {{Wh}}: Template:Tle → == Welcome! ==
|
- Complex page name examples
3=de | de:Wikipedia | Benutzer Diskussion:Andreas_06/Spielwiese/Stadien_der_Fußball-Bundesliga |
3=fr | fr:Wikipédia | Discussion aide:Catégorie/Archive3#Appels à volontaires pour Aide à la conception de l'arborescence |
3=yi | yi:Wikipedia | ענדערן הילף:אינהאלט |
3=pt | pt:Wikipedia | Categoria:Cidades fantasmas da Califórnia • Predefinição Discussão:!Info pessoal |
3= | en:Wikipedia | Template talk:Welcome/fr#Pas assez informatif |
3=nl:b | nl:Wikibooks | Scalable Vector Graphics/Stijl |
3=en:d | en:Wikidata | Project chat |
3=en:n | en:Wikinews | Egyptian MP calls for web porn ban |
3=fi:q | fi:Wikiquote | Elizabeth II |
3=es:s | es:Wikisource | Archivo:Las Maravillas Del Cielo pg 7.jpg |
3=sv:v | sv:Wikiversity | Surdegsbakning för hemmabagaren |
3=pl:voy | pl:Wikivoyage | San Francisco |
3=lt:wikt | lt:Wiktionary | Sąrašas:Kinų hieroglifų raktai |
3=m | Metawiki | VisualEditor/Newsletter/2014/November/ka |
3=mw | Mediawiki | Extension:ParserFunctions/it |
3=species | Wikispecies | Verrucaria halizoa |
3=en:commons | en:Commons | Template:W |