Vorlage:Numbered subpages/doc: Unterschied zwischen den Versionen
en>Andrybak (→Parameters: trim) |
Becher (Diskussion | Beiträge) K (1 Version importiert) |
(kein Unterschied)
|
Aktuelle Version vom 10. Juni 2020, 12:12 Uhr
{{#invoke:Message box|mbox}} {{#invoke:Lua banner|main}}
Template to show numbered subpages arranged ascendingly from 1 to maximum.
Usage
Simple
{{Numbered subpages}}
Full parameters
{{Numbered subpages |max= |min= |missing= |headertemplate= |SPAN= |preload= |inline= }}
Parameters
|max=number
- You can use the
|max=
parameter to change the number of transcluded and linked subpages. |missing=stop
- To terminate the loop when a non-existing subpage is encountered.
|missing=skip
- To skip non-existing subpages.
|missing=link
- To link, but not transclude missing subpages.
|missing=link
and|preload=preload template
- To use a preload template for missing pages links.
|inline=true
- Boolean parameter to switch from default {{Portal subpage}} to {{Portal subpage inline}}. This is well suited for single-hook "Did you know" subpages.
Customization of {{Portal subpage}}
|headertemplate=
- To customize box header template. By default, subpage
/box-header
of the portal is used.
Parameter |SPAN=
is passed to {{Portal subpage}} as is. See Template:Portal subpage/doc for details.
Examples
This is an example of use of the template as it would be found on the "Selected quotes" sub-page that is a component of a portal created using the {{box portal skeleton}}. Simply placing the template on the page is all that is needed to show all selected quotes stored in sub-pages linked to it, however using the template as part of a fully formed description makes it easier for other editors to modify the page as needed.
<source lang="moin">
Instructions
- Add a new Selected quote to the next available subpage using {{cquote}}.
- Vorlage:Edit
{{safesubst:#invoke:numbered subpages|main}}
Purge server cache </source>
Used templates
- {{subpage}}
See also
{{#invoke:Navbar|navbar}} Portal content templates
- To display "selected content" on the portal main page
- {{Transclude list item excerpts as random slideshow}}—transcludes excerpts from recognized content lists, which are populated by a bot.
- {{Transclude random subpage}}—transcludes random portal subpage.
- {{Random portal component}}—transcludes random portal subpage.
- {{Random subpage}}—transcludes random portal subpages.
- To organize "selected content" on subpages
- {{Numbered subpages}}—outputs an automatic index, transcluding numbered subpages.
- {{Portal subpage}}—outputs a box linking to and transcluding a single subpage.
- {{Portal subpage inline}}—outputs an unordered list item linking to and transcluding a single subpage.
Main portal page formatting templates
- {{Box-header}}
- {{Box-header-plain}}
- {{Box-header-round}}
- {{Box-header-square}}
- {{Box-header-watch}}
- {{Box-footer}}
Templates that configure links
- {{Portal}}
- {{Portal bar}}
- {{Portal-inline}}
- {{Portals}}
- {{Portal-image}}
- {{Portals browsebar}}
- {{Related portals}}
- {{Related portals2}}
- {{Wikimedia for portals}}
Selected page templates, used on subpages of older portals
- {{Selected article}}
- {{Selected biography}}
- {{Selected business}}
- {{Selected DYK}}
- {{Selected ingredient}}
- {{Selected location}}
- {{Selected picture}}
- {{Selected product}}
- {{Selected publication}}
- {{Selected quote}}
- {{Selected recipe}}
- {{Selected X}}
Related templates
- {{Project template list}}
- {{#Invoke:Tlg|main}} (deleted)—Used to create portal main pages.
- {{Random box-header subpage}}—randomized selection from {{Box-header/1}} to {{Box-header/42}}.
{{#invoke:Navbox|navbox}}