Template:Plink: Difference between revisions
Jump to navigation
Jump to search
Content added Content deleted
(size param) |
No edit summary |
||
Line 1: | Line 1: | ||
<includeonly><span class="plink-template">[[File:{{{pic|{{{1}}}}}}.png|link={{{1}}} |
<includeonly><span class="plink-template">[[File:{{{pic|{{{1}}}}}}.png|link={{{1}}}|{{{size|30}}}px]]</span>[[{{{1}}}|{{{txt|{{{1}}}}}}]]</includeonly><noinclude>{{/doc}}</noinclude> |
Latest revision as of 23:21, 1 November 2024
Template documentation
This documentation is transcluded from Template:Plink/doc. [edit] [history] [purge]
The picture link template creates an image and links it to the page as well as including text.
This template is not intended to be commonly used in mainspace articles. It is primarily used in navboxes and tables to add images to help with navigation. In most other cases, pages should be linked with normal markup and without an image.
Usage
{{plink|item|pic=file name|txt=text}}
Examples
Code | Produces | Standard syntax |
---|---|---|
{{plink|Hammermage potion}}
|
Hammermage potion | [[File:Hammermage potion.png|link=Hammermage potion]] [[Hammermage potion]]
|
{{plink|Hammermage potion|size=50}}
|
Hammermage potion | [[File:Hammermage potion.png|50px|link=Hammermage potion]] [[Hammermage potion]]
|
{{plink|Health potion|pic=Hammermage potion}}
|
Health potion | [[File:Hammermage potion.png|link=Health potion]] [[Health potion]]
|
{{plink|Hammermage potion|txt=Potion}}
|
Potion | [[File:Hammermage potion.png|link=Hammermage potion]] [[Hammermage potion|Potion]]
|
{{plink|Health potion|pic=Hammermage potion|txt=Potion}}
|
Potion | [[File:Hammermage potion.png|link=Health potion]] [[Health potion|Potion]]
|
Parameters
The 'Picture Link' (plink) template is used to create item image + text links.
Parameter | Description | Type | Status | |
---|---|---|---|---|
Item | 1 | The item to link to and display | Page name | required |
Picture | pic | The name of the image file; do not include 'File:' or '.png'
| File | optional |
Text override | txt | Override the displayed link text.
| String | optional |
Size | size | Sets custom size (in px). | Number | optional |