Template:Subpage other/doc

Revision as of 12:28, 19 October 2020 by Caleb Cooper (talk | contribs) (Created page with "{{Documentation subpage}} {{Commons Import}} <!-- Please place categories where indicated at the bottom of this page and interwikis at Wikidata (see Wikipedia:Wikidata) -...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
This content is in the Template Namespace. Used for page-templates that can be re-used across the wiki.


Usage

This template checks whether the current page is a subpage or not. A subpage is a page that has a slash:

[[Template:Parentpage/Subpage]]

Exception: in article space (mainspace) the slash is part of the title, and there are no subpages. Example, AC/DC is a parent page not a subpage.

Usage example: both Template:Infobox element isotopes and Template:Infobox element isotopes/infotable use documentation page Template:Infobox element isotopes/doc. We only want to categorise the parent page. So in the /doc page we add:

{{Subpage other|<!-- do not categorise -->|[[Category:Chemical element infobox]]}}
Note
wikipedia:WP:Subpage uses an other definition than magic word {{SUBPAGENAME}}. This template uses the former definition (pagename has an after-slash part).

See also

For more detail see wikipedia: wikipedia:emplate:Subpage other