Template:Float tag: Difference between revisions
Jump to navigation
Jump to search
going meta - a template to standardize the other floating tag templates and allow easy creation of new ones |
silly me, need to use HTML for stuff inside ifs |
||
| Line 1: | Line 1: | ||
{| class="floatright" style="background:{{{text-background|transparent}}}; border: thin solid rgb(0,0,0); width:300px;" | {| class="floatright" style="background:{{{text-background|transparent}}}; border: thin solid rgb(0,0,0); width:300px;" | ||
|- | |- | ||
{{#if:{{{icon|}}}| | {{#if:{{{icon|}}}|<td style="background:{{{icon-background|transparent}}};" width="40px">[[Image:{{{icon}}}|{{{icon-width|30px}}}|center|Icon]]</td>}} | ||
| style="font-size:75%;" | {{{text}}} | | style="font-size:75%;" | {{{text}}} | ||
|}<noinclude> | |}<noinclude> | ||
Revision as of 00:47, 13 August 2007
{{#if:|}}
| [[Image:{{{icon}}}|30px|center|Icon]] |
| {{{text}}} |
This meta-template is intended for creating other templates of a standard "floating tag" design. It has only one mandatory parameter, "text"; the rest are optional.
A full declaration:
{{float tag
|text = String of displayed text
|icon = Filename.png
|text-background = #ff6600 (default is transparent)
|icon-background = red (default is transparent, which shows text-background)
|icon-width = 20px (defaults to 30px, don't go over 40px)
}}