Open main menu

Project: Gorgon Wiki β

Changes

Template:TEMPLATENAME/doc

1,676 bytes added, 09:28, 10 April 2016
copy-over from latest version on http://templates.wikia.com/wiki/Template:TEMPLATENAME/doc
{{Documentation subpage}}
<!-- Categories where indicated at the bottom of this page, please -->

When used on a template's <code>/doc</code> subpage, {{tl|{{TEMPLATENAMEE}}}} evaluates to the name of the associated template. The result will be accurate when the end page is either the <code>/doc</code> subpage or the actual template page. The template makes a special case for the <code>{{ns:Template}}:</code> namespace: the <code>{{ns:Template}}:</code> prefix will be removed.

Note that the result will not be URL-safe. For a URL-encoded version, see {{tl|TEMPLATENAMEE}}.

===Parameters===
; {{{1}}} {{nobold|{{smaller|(i.e. the first unnamed parameter)}} or ''require''}}
: Sets the subpage from which the template extracts a name. If the parameter's value does not match the current subpage,{{clarify|July 2014}} nothing will be returned. This is useful in preventing potentially endless [[Recursion (computer science)|recursive loops]] on some templates pages that might otherwise reference themselves.

; ''docpage'' {{nobold|or ''override''}}
: Use to indicate the documentation page's location if it is other than the subpage <code>/doc</code>, e.g. <code>{{((}}{{TEMPLATENAME}}{{!}}docpage=Documentation{{))}}</code> if the subpage is <code>/Documentation</code>.

The following subpages will always be removed [?] :
* /doc
* /sandbox
* /testcases

== See also ==
* {{tl|TEMPLATENAMEE}}

<includeonly>{{#ifeq:{{SUBPAGENAME}}|sandbox |
| <!-- Categories below this line, please: -->
{{DEFAULTSORT:Templatename}}
[[{{ns:Category}}:Template documentation]]
[[Category:Template namespace templates]]
[[Category:Wikipedia variable-like templates]]
}}</includeonly>
1,071
edits