Template:Canvas snippet/ifparam
Jump to navigation
Jump to search
|
/ifparam parameters:
Shown text: | |
|
{{{ifdef}}} |
The following template description is not displayed when the template is inserted in an article.
Goal
This template is used by {{canvas snippet}} to show different texts depending on if one of its parameters is defined or not.
Note The frame around the sample above will not be visible when used with {{canvas snippet}}.
Usage
{{canvas snippet/ifparam
| param =
| ifdef =
| else =
}}
The only mandatory parameter is param.
- param
- Name of the parameter in {{Canvas snippet}}.
- ifdef
- Wiki text to use if the parameter is defined.
- else
- Wiki text to use if the parameter is not defined.
Technical details
The template adds a new row with one cell spanning two columns to a table. Each cell is used for formatting one of the parameters in {{canvas snippet}} that documents a canvas snippet.