Template:Name
Description
This template is used to insert an image next to an article name, resize the image to 20px wide, create a link to the article, and a parameter to display quantity or other detail after the article name and link.
Image size can be adjusted using the parameter "size".
Usage
This template can be used by entering the following onto a relevant page.
{{name|''item name''|''detail''}}
Optional Parameters
If used together with "detail" these should be entered after the detail value.
- size=Adjust the width in px the image displays at (e.g. size=32)
- image=Overrides the image matching the item name (e.g. image=Mickey Mouse.png)
- link=Link to an alternative page
Examples
The most common use of this template doesn't define parameters by name, but by order.
{{name|Apple|5}}
results in...
Apple (5)
{{name|Buzz Lightyear's Space Pack}}
results in...
- Optional Parameter Examples
The "detail" parameter can be any value, including another template
{{name|Donald Duck|{{price|100}}}}
results in...
Donald Duck ( 100)
The parameter "size" overrides the default (20px) image size
{{name|Wedding Cake|3|size=48}}
results in...
Wedding Cake (3)
Optional parameters can be used without a "detail" value
{{name|Scrooge McDuck|size=48}}
results in...
By default the image and link are the "name" value. Each can be overridden using named parameters "image" and "link".
{{name|Goofy|image=Mickey Mouse.png}}
results in...
{{name|Goofy|link=Mickey Mouse}}
results in...
To provide different linked text but the same page link, use the standard MediaWiki syntax for escaping a pipe character in a template:
{{name|Cute Nightstand (2)|link=Cute Nightstand (2){{!}}Cute Nightstand}}
results in...
Optional parameters can also be combined
{{name|Crab|3|size=36|link=:Category:Seafood{{!}}Seafood}}
results in...
Seafood (3)