Template:Documentation/doc

From DDwiki
Revision as of 01:44, 16 April 2012 by Madness (Talk | contribs) (See also)

Jump to: navigation, search

This is the {{documentation}} template.

This template displays a green doc box like you are seeing now, and automatically loads the content from a /doc subpage.

Usage

This template is used without any parameters, placed at the bottom of the template or page being documented, within <noinclude>:

<!--Last line of your template code--><noinclude>

{{documentation}}
<!-- Add categories and interwikis to the /doc subpage, not here! -->
</noinclude>

Then this template automatically loads the content from the /doc subpage of the template it is used on.

Best practice

The code should be added at the bottom of the template code, with no space before Template:Tag (which would cause extra space on pages where the template is used).

Categories and interwiki links that apply to the template itself should be added to the bottom of the /doc subpage, inside Template:Tag tags.

If the documentation page contains Template:Tag or Template:Tag tags as part of the visible documentation text, replace the "<" with "&lt;".

See also

  • {{documentation subpage}} – Used at the top of /doc subpages to explain what they are and to link back to the page they document.