Template:Item link 2-cell/doc
This template is similar to the {{item link}}
template, but is meant for use in tables where the item image and item name are to be placed in separate, horizontally adjacent table cells. This allows all item names to align with each other, images will be centered (but can be aligned as well with the istyle parameter).
Usage
Use the shortcut {{il2c}}
for convenience:
{{il2c|<item name>|size=}}
This displays a centered image link for the item in one cell, and a text link in the next. No CSS may precede the template, because CSS style is used within the template to center the image. All additional styling must be sent to the template via lstyle, istyle, and tstyle.
- unnamed parameter 1
- Item name.
- tstyle, unnamed parameter 2
- Optional parameter to set the CSS style of the cell containing the item name.
- istyle
- Optional parameter to set the CSS style of the cell containing the item image.
- lstyle
- Optional parameter to set the CSS style of both cells (item image and item name).
- attr
- Optional parameter to set cell attributes (e.g., rowspan).
- A colon can be used between the attribute and its value, or {{=}}.
- The default middle vertical alignment for rowspans greater than 1 can be changed with valign=top (attr=valign:top).
- ext
- Optional parameter to set the image file extension (e.g. gif); default is png.
- size
- Optional parameter to set the image width.
- id
- Optional parameter to display the item ID.
- npcid
- Optional parameter to display the NPC ID.
- t
- Optional parameter to set custom link text. This replaces the item name displayed, while keeping the link destination and image intact.
- image
- Optional parameter to set a custom image. This replaces the image displayed, while keeping the link destination and text intact. Enter as a naked image name with no [[File: code, eg. Paintbrush.png.
- nl
- Optional flag to no-link the item and image. User will be unable to click either the image or the item name. Any value may be sent to trigger the flag.
- anchor
- Optional flag to create an anchor.
- icons
- Optional flag to alter the display of icons, =no (disables), =br (breaks to next line), =small (smaller icons), br and small may be combined (see example below).
Example
Code:
|
Produces:
|