Template:Basepage subpage/doc
This template detects whether the page it is used on is a subpage, and outputs different content accordingly.
Basic usage
[edit]The template takes three parameters, one containing the wikicode to output if used on a basepage, the second containing the wikicode to output if used on a subpage, and the third the content to output if used on a subsubpage or lower. The third parameter is optional, if not provided then the second parameter will be provided for subsubpages and lower.
{{Basepage subpage|result if basepage|result if subpage|result if subsubpage}}
page parameter
[edit]The "page" parameter can be used to force the template to display the output it would produce on a specific page, regardless of where the template actually is.
{{Basepage subpage|result if basepage|result if subpage|result if subsubpage|page=user:example/test}}
Will force the template to display result if subpage
, regardless of where it actually is.