Template:PAGENAMEBASE/doc
Jump to navigation
Jump to search
This is a documentation subpage for Template:PAGENAMEBASE. It may contain usage information, categories and other content that is not part of the original template page. |
Warning | This template is used on 725,000+ pages. To avoid large-scale disruption and unnecessary server load, any changes to this template should first be tested in its /sandbox or /testcases subpages or in your own user subpage. The tested changes can then be added to this page in a single edit. Please consider discussing any changes on the talk page before implementing them. |
This template uses Lua: |
Usage
This template returns the current {{PAGENAME}}
minus (text in parentheses) or the final set of parentheses where more than one set exist.
e.g. {{PAGENAMEBASE}}
on page Chiton (genus) returns PAGENAMEBASE/doc
- on Sweet Dreams (Are Made of This) (album) returns PAGENAMEBASE/doc
- on Sweet Dreams (Are Made of This) returns PAGENAMEBASE/doc
- on Stadion der Freundschaft (Frankfurt (Oder)) returns PAGENAMEBASE/doc
Can also pass an optional page parameter:
{{PAGENAMEBASE|foo (bar)}}
→ "PAGENAMEBASE/doc"{{PAGENAMEBASE|foo bar}}
→ "PAGENAMEBASE/doc"
It is not to be confused with {{BASEPAGENAME}}
, which is a magic word that strips subpages, not parentheses.
See also
- Help:Magic words
- String-handling templates
- {{PAGENAME}} (variant to strip anything in parentheses from the title)
- {{FULLPAGENAME}} (including namespace)
- {{Link without disambiguator}}
Categories:
- Pages with non-numeric formatnum arguments
- Template documentation pages
- Pages with broken file links
- Exclude in print
- Infobox templates
- Lua-based templates
- Mbox and messagebox templates
- Pages used in system messages needing protection
- Pages with TemplateStyles errors
- Template documentation
- Template namespace templates
- Templates
- Templates based on the Infobox Lua module
- Templates generating microformats
- Templates that add a tracking category
- Templates using TemplateData
- Templates with documentation
- Wikipedia metatemplates