Template:Button: Difference between revisions
From A KoL Wiki
imported>JohnAnon mNo edit summary |
imported>Fig bucket m allow a width argument |
||
Line 1: | Line 1: | ||
<includeonly>{| cellspacing="0" style="{{#ifeq:{{{center|y}}}|y|margin-left: auto; margin-right: auto; margin-bottom: 8px;|}} border: 2px black solid; font-family: Arial, Helvetica, sans-serif; {{#ifeq:{{{disabled|n}}}|y|color:#CCCCCC;|}} font-size: 10pt; font-weight: bold; background-color: #FFFFFF; padding-right: 8px; padding-left: 8px;" id="{{{1}}}" | <includeonly>{| cellspacing="0" style="{{#ifeq:{{{center|y}}}|y|margin-left: auto; margin-right: auto; margin-bottom: 8px;|}} border: 2px black solid; font-family: Arial, Helvetica, sans-serif; {{#ifeq:{{{disabled|n}}}|y|color:#CCCCCC;|}} font-size: 10pt; font-weight: bold; background-color: #FFFFFF; padding-right: 8px; padding-left: 8px;{{#if:{{{width|}}}|width:{{{width}}};}}" id="{{{1}}}" | ||
|- | |- | ||
| {{{1}}} | | {{{1}}} | ||
Line 15: | Line 15: | ||
*To create a grayed out button: | *To create a grayed out button: | ||
*:<nowiki>{{button|Text|disabled=y}}</nowiki> | *:<nowiki>{{button|Text|disabled=y}}</nowiki> | ||
*Width may be specified with the <code>width</code> argument. | |||
In either version, "Text" can be anything, including wiki links to other pages. | In either version, "Text" can be anything, including wiki links to other pages. |
Revision as of 12:02, 9 October 2014
[edit]
{{Button}}
{| cellspacing="0" style="{{#ifeq:{{{center|y}}}|y|margin-left: auto; margin-right: auto; margin-bottom: 8px;|}} border: 2px black solid; font-family: Arial, Helvetica, sans-serif; {{#ifeq:{{{disabled|n}}}|y|color:#CCCCCC;|}} font-size: 10pt; font-weight: bold; background-color: #FFFFFF; padding-right: 8px; padding-left: 8px;{{#if:{{{width|}}}|width:{{{width}}};}}" id="{{{1}}}"
|- | {{{1}}}
|}Creates a button in the style typically seen in the game.
Usage
- To create a centered button:
- {{button|Text}}
- To create an un-centered button (with no left/right margins), use
- {{button|Text|center=n}}
- To create a grayed out button:
- {{button|Text|disabled=y}}
- Width may be specified with the
width
argument.
In either version, "Text" can be anything, including wiki links to other pages.
Examples
{{button|Log In}}
yields:
Log In |
{{button|Buy Item}}
yields:
Buy Item |
{{button|Sail Away! (3)}}
yields:
Sail Away! (3) |
{{button|[[Loathing Legion hammer]]|center=n}}
yields
Loathing Legion hammer |
{{button|Sneak past it|disabled=y}}
yields:
Sneak past it |