Template:Subpage tabs: Difference between revisions
From Tardis Wiki, the free Doctor Who reference
Bongolium500 (talk | contribs) m (Bongolium500 moved page User:Bongolium500/subpage tabs to Template:Subpage tabs) |
Bongolium500 (talk | contribs) No edit summary |
||
Line 1: | Line 1: | ||
{{#invoke:Subpage tabs|produceTabs}} | <includeonly>{{#invoke:Subpage tabs|produceTabs}}</includeonly><noinclude>{{TempInuse}}{{documentation}}[[Category:Navigation templates]]</noinclude> |
Revision as of 20:17, 26 May 2023
This template isn't fully cooked yet
We're still alpha testing it. You may find it used on live pages, but please do not use it yourself until this message has been removed.
Instructions for {{Subpage tabs}}
{{Subpage tabs}} creates a series of tab-like links to the subpages of the page they're placed on. Basic usage is very simple. Simply place {{subpage tabs}} at the top of the page, above any other templates. This will automatically produce links to the following standardised subpages, if they exist for this page, in this order:
By default, tabs are created for the current page, or it's base page one level higher in the subpage order. If required, a different page can be specified and tabs will instead be displayed for that page. This done using |p=. For example, to generate tabs for Davros, you'd type:
- Biography
- Spoilers
- Physical appearance
- Other realities
- Non-valid material
- Promotion
- Gallery
- Appearances
{{subpage tabs|Custom subpage 1|Custom subpage 2}}You can specify as many additional subpages as necassary. Note that additional subpages always display after custom ones.
By default, tabs are created for the current page, or it's base page one level higher in the subpage order. If required, a different page can be specified and tabs will instead be displayed for that page. This done using |p=. For example, to generate tabs for Davros, you'd type:
{{subpage tabs|p=Davros}}The following code produces the series of tabs shown below:
{{subpage tabs|p=Davros|Custom subpage}}
Technical documentation
All heavy lifting for this template is done in Module:Subpage tabs. One important part is the table defined on line 3: this controls which subpages are looked for automatically and in what order they are displayed.
Styling for this template is largely at /styles.css. All colours are defined in MediaWiki:Gadget-ms-Tardis.css.