Template:TlDoc: Difference between revisions

From Citizendium
Jump to navigation Jump to search
imported>Caesar Schinas
mNo edit summary
imported>Caesar Schinas
("standard" notice appearance)
Line 1: Line 1:
{{#ifexist: {{FULLPAGENAME}}/doc
<div style="border:1px #bbb solid; background-color:#eee; padding:0.5em; margin:0.5em 0">{{#ifexist: {{FULLPAGENAME}}/doc
|''This documentation is transcluded from'' [[{{FULLPAGENAME}}/doc]] <small>([{{fullurl:{{FULLPAGENAME}}/doc|action=edit}} edit] &#124; [{{fullurl:{{FULLPAGENAME}}/doc|action=history}} history])</small>
|''This documentation is transcluded from'' [[{{FULLPAGENAME}}/doc]] <small>([{{fullurl:{{FULLPAGENAME}}/doc|action=edit}} edit] &#124; [{{fullurl:{{FULLPAGENAME}}/doc|action=history}} history])</small></div>
 
{{{{FULLPAGENAME}}/doc}}
{{{{FULLPAGENAME}}/doc}}


|''No documentation has yet been written for this template.'' [{{fullurl:{{FULLPAGENAME}}/doc|action=edit&preload=Template:TlDoc/preload&editintro=Template:TlDoc/editintro}} Create Documentation]
|''No documentation has yet been written for this template.'' [{{fullurl:{{FULLPAGENAME}}/doc|action=edit&preload=Template:TlDoc/preload&editintro=Template:TlDoc/editintro}} Create Documentation]</div>
}}
}}

Revision as of 08:06, 14 May 2009

This documentation is transcluded from Template:TlDoc/doc (edit | history)

{{TlDoc}} is used to include template documentation, stored on the .../doc subpage of each template, when a template page is viewed directly.

Usage

Wrap the call to {{TlDoc}} inside <noinclude>...</noinclude> tags as seen below, to prevent the documentation from being shown on pages where the template is used.
<includeonly>
...template code here...
</includeonly><noinclude>{{TlDoc}}</noinclude>

The template has one optional parameter, complex, which causes a message to be displayed saying that the template uses complex code.

Examples

{{TlDoc}}
gives

This documentation is transcluded from Template:TlDoc/doc (edit | history)

Template loop detected: Template:TlDoc/doc


{{TlDoc|complex}}
gives

This documentation is transcluded from Template:TlDoc/doc (edit | history)

Template loop detected: Template:TlDoc/doc