Template:DYK mbox

From blackwiki
Revision as of 15:10, 27 January 2013 by imported>John Cline (ce documentation)
Jump to navigation Jump to search
The above documentation is transcluded from Special:ExpandTemplates/doc. (edit | history)
Please add categories and interwikis to the /doc subpage. Subpages of this page.
A print version of this template exists at /Print. If you make a change to this template, please update the print version as well.
This template uses the following internal syntax

<table class="{{#if:{{{table class|}}}|{{{table class}}}|plainlinks ombox dykbox-notice}}" style="{{#if:{{{table style|}}}|{{{table style}}}|}}">{{#if:{{{table header|}}}|{{{table header}}}|}}{{#if:{{{table row|}}}|{{{table row}}}|<tr>}}{{#if:{{{table data|}}}|{{{table data}}}|<td class="mbox-image">{{#if:{{{file|}}}|[[File:{{{file}}}|{{#if:{{{file size|}}}|{{{file size}}}x{{{file size}}}px|33x33px}}|{{#if:{{{file link|}}}|link={{{file link}}}|link=}}|{{#if:{{{alter|}}}|alt={{{alter}}}|alt=}}]]|[[File:GAflag.gif|33x33px|link=|alt=]]}}</td><td class="mbox-text" style="{{#if:{{{td style|}}}|{{{td style}}}|}}">{{{text}}}</td>}}{{#if:{{{file2|}}}|<td><span style="float:right">{{{file2}}}</span></td>|}}</tr></table>

The default for {{DYK/mbox}} produces:
</table>
Template documentation[view] [edit] [history] [purge]
Shortcut:

{{DYK mbox}} is a messaging utility template for posting messages related to Did you knowDYK comment symbol operations. It also supports other templates, internally—to facilitate interactive ease of use, on special pages, and editing scripts, used for the administration of Did you knowDYK comment symbol.

Template {{DYK mbox}}

This template was developed for the specialized needs of Did you knowDYK comment symbol.

Usage

Either the basic syntax, {{DYK mbox}} or the shortcut, {{DYKM}} will produce:


</table>


You can either use {{DYKM|text=Inserts your custom message.}}, or default through the unnamed parameter switch, {{DYKM|Inserts your custom message.}} to produce the following:


</table>


You can use |xfile= to eliminate the image; the text floats to the left margin, and the box only grows as large as the included text; {{DYKM|xfile=true}} is shown below:


</table>


Or you could use a non printable character in place of the image {{DYKM|file= |text}} which maintains the image's margin as if it were in place and the size of the box is maintained as shown below:


</table>


The |small= parameter switches from the 80% width, center aligned, message box to a smaller box that aligns to the right side of the line it is added to. It uses similar parameters as the main box except they begin with a small s, for example the text parameter for the small box is |stext=. Therefor the following code: {{DYKM|small=y|stext=This is the small box text}} produces the following:


</table>


Several other parameters are incorporated that modify the template's output for specialized use (examples are shown below)).

Examples

Custom messaging examples are included as expandable content.

See also