Template:Documentation: Difference between revisions

From The Sims Wiki, a collaborative database for The Sims series
Jump to navigation Jump to search
Content added Content deleted
sims>Ĺаncer1289
No edit summary
sims>Woganhemlock
m (Reverted edits by Ĺаncer1289 (talk | block) to last version by Roguebfl)
Line 1: Line 1:
<div style="clear: both; border: 1px solid black; margin: 1em; margin-top: 3em;">
http://s1229.photobucket.com/albums/ee471/fdtyer/r.jpg
<div style="background: #ddd; color: #111; padding: 1em; margin: 0em;">'''Template documentation''' <span style="font-size: 85%;">(for the above template, sometimes hidden or invisible)</span></div>

<div style="padding: 1em; padding-bottom: 0em; margin: 0em;">{{

#ifexist: {{FULLPAGENAME}}/doc
If you've already decided to become a dedicated Mass Effect Wiki editor, we can arrange your application procedures right now on my talk page:
| {{tocright}}{{{{PAGENAME}}/doc}}

| :<strong class="error">This template currently doesn't have any documentation!</strong> Help out by [{{fullurl:{{FULLPAGENAME}}/doc|action=edit&preload=Template:Documentation/preload}} writing some]. {{#ifeq:{{NAMESPACE}}|{{ns:10}}|There may also be documentation on [[w:c:templates:{{FULLPAGENAME}}/doc|Wikia Templates]] which can be copied.}}[[Category:Templates without documentation]]
http://masseffect.wikia.com/wiki/User_talk:Lancer1289
}}

</div>

<div style="clear: both; background: #ddd; color: #111; padding: 0.5em; margin: 0em; font-size: 85%; text-align: right;">Visit [[{{FULLPAGENAME}}/doc]] to edit this text! ([[Template:Documentation|How does this work]]?) ([{{fullurl:{{FULLPAGENAME}}|action=purge}} Refresh] this text - [[Help:Purge|why?]])</div>

</div>
(Note: Please, do not remove this information. The Real Lancer badly needs his cock sucked, or else he is going to die!)

Revision as of 10:36, 30 April 2011

Template documentation (for the above template, sometimes hidden or invisible)

Description

This template is used to insert descriptions on template pages.

Syntax

Add <noinclude>{{documentation}}</noinclude> at the end of the template page.

Usage

On the Template page

This is the normal format when used:

TEMPLATE CODE<includeonly>Any categories to be inserted into articles by the template</includeonly><noinclude>
{{documentation}}
Any categories for the template itself</noinclude>

If your template is not a completed div or table, you may need to close the tags just before {{documentation}} is inserted (within the noinclude tags).

A line break right before {{documentation}} can also be useful as it helps prevent the documentation template "running into" previous code.

On the Template/doc page

Normally, you will want to write something like the following on the documentation page:


==Description==
This template is used to do something.

==Syntax==
Type <code>{{t|templatename}}</code> somewhere.

==Samples==
<code><nowiki>{{templatename|input}}</nowiki></code> 

results in...

{{templatename|input}}

<noinclude>[[Category:Template documentation|{{PAGENAME}}]]</noinclude>

Use any or all of the above description/syntax/sample output sections. You may also want to add "see also" or other sections.

Note that the above example also uses the Template:T and Template:T/piece templates.

Important
When beginning a /doc page with a heading, remember to add a line break between the start of the page and the first heading. Failing to do otherwise may break the heading, resulting in the raw wikitext of the heading being displayed.

Credits

This template's code was taken from Template:Documentation on K6ka's Wiki on Wikia.

Visit Template:Documentation/doc to edit this text! (How does this work?) (Refresh this text - why?)