Template:Xpdoc/doc: Difference between revisions
Template page
More actions
usage-notes=In the case of demonstrating a template, values of unnamed parameters of this template are trimmed, so this template cannot be used for demonstrating the effect of spaces at the start or e |
mNo edit summary |
||
| Line 21: | Line 21: | ||
|usergroup=all | |usergroup=all | ||
|placement= | |placement= | ||
|usage-notes=In the case of demonstrating a template, values of unnamed parameters of this template are trimmed, so | |usage-notes=In the case of demonstrating a template, values of unnamed parameters of this template are trimmed, so [[Template:Xpdoc]] cannot be used for demonstrating the effect of spaces at the start or end of an unnamed parameter. | ||
|type= | |type= | ||
|example=Creator:Vincent van Gogh | |example=Creator:Vincent van Gogh | ||
Revision as of 23:27, 18 September 2010
The expansion demo templates show, for documentation:
- some wikitext
- its rendering
without the need of repeating the parameters in the wikitext.
Usage
{{xpdopc |1= |2= |gives= }}
In the case of demonstrating a template, values of unnamed parameters of this template are trimmed, so Template:Xpdoc cannot be used for demonstrating the effect of spaces at the start or end of an unnamed parameter.
Template parameters
| Parameter | Description | Default | Status | |
|---|---|---|---|---|
1 | name of parser function, a colon, and the first parameter, or name of template | empty | required | |
2 | the parameter after the first pipe | empty | optional | |
gives | text (or the empty string) to replace the word "gives", e.g. gives={{!}}{{!}} to produce "||", for use in a table | gives | optional | |
Additional information
The template is intended to be used in the following namespaces: the Template namespace
The template is intended to be used by the following user groups: all users
Example
{{xpdopc|Creator:Vincent van Gogh}}
renders as:
See also
Naming scheme:
- o = double opening braces
- c = double closing braces
This is a simplified version of m:Template:Xpdop3c.
More examples
{{xpdopc|ISOdate|2009-04-03}} produces: "Template:Xpdopc".