Difference between revisions of "Template:Namespace detect"

From CWCki
Jump to navigation Jump to search
(Corrected formatting.)
Line 73: Line 73:


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

Revision as of 19:44, 3 December 2010

Usage

These usage notes will not be included in articles bearing this template.

This is a metatemplate used to help other templates detect what type of page they are on. The format for using this template is as follows:

{{namespace detect | main = Article text | talk = Talk page text | other = Other pages text }}

- Displays: Other pages text

In the above example, the template displayed the message for "other pages", because this page is not a main or talk page. However, if we included a parameter for templates...


{{namespace detect | main = Article text | talk = Talk page text | other = Other pages text | template = Template pages text }}


- Displays: Template pages text