Difference between revisions of "Module:NUMBEROFSECTIONS/doc"
Jump to navigation
Jump to search
blackwiki>Fred Gandt m (clarify) |
blackwiki>Fred Gandt (update per update) |
||
| Line 1: | Line 1: | ||
| − | {{Module rating |alpha}} | + | {{Module rating|alpha}} |
<!-- Please place categories where indicated at the bottom of this page and interwikis at Wikidata (see [[Wikipedia:Wikidata]]) --> | <!-- Please place categories where indicated at the bottom of this page and interwikis at Wikidata (see [[Wikipedia:Wikidata]]) --> | ||
== Usage == | == Usage == | ||
{{important|This module is invoked by {{tl|NUMBEROFSECTIONS}} and may be expanded to include any other NUMBEROFthings.}} | {{important|This module is invoked by {{tl|NUMBEROFSECTIONS}} and may be expanded to include any other NUMBEROFthings.}} | ||
; <code>sections</code> | ; <code>sections</code> | ||
| − | : <code><nowiki>{{</nowiki> #invoke:NUMBEROF | sections | page name ''[ | + | : <code><nowiki>{{</nowiki> #invoke:NUMBEROF | sections | page name ''[ # page name [ # ... <nowiki>] ]</nowiki>'' | level = section level number(s) }}</code> |
| − | : | + | :# Multiple ''page name''s <small>'''(at least one required)'''</small> are the <code>#</code> delimited names of any Wikipedia pages (including namespaces). |
| − | : | + | :# ''section level(s)'' <small>'''(required)'''</small> is any group of numerals between ''1'' and ''6'' (inclusive) ''e.g.'' <code>435</code> or <code>5 3 4</code> equates to: |
::: sections with a level <code>3</code> ( "===" ), <code>4</code> ( "====" ) or <code>5</code> ( "=====" ) heading. | ::: sections with a level <code>3</code> ( "===" ), <code>4</code> ( "====" ) or <code>5</code> ( "=====" ) heading. | ||
: <code><nowiki>{{#invoke:NUMBEROF|sections|Wikipedia:Village pump (technical)|level=2}}</nowiki></code> produces <code>{{NUMBEROFSECTIONS|Wikipedia:Village pump (technical)}}</code> | : <code><nowiki>{{#invoke:NUMBEROF|sections|Wikipedia:Village pump (technical)|level=2}}</nowiki></code> produces <code>{{NUMBEROFSECTIONS|Wikipedia:Village pump (technical)}}</code> | ||
| + | : <code><nowiki>{{#invoke:NUMBEROF|sections|Wikipedia:Village pump (technical)#Wikipedia:Village pump (proposals)|level=2}}</nowiki></code> produces <code>{{NUMBEROFSECTIONS|Wikipedia:Village pump (technical)#Wikipedia:Village pump (proposals)}}</code> | ||
<includeonly>{{#ifeq:{{SUBPAGENAME}}|sandbox | | | <includeonly>{{#ifeq:{{SUBPAGENAME}}|sandbox | | | ||
Revision as of 14:23, 25 March 2016
| This module is rated as alpha. It is ready for third-party input, and may be used on a few pages to see if problems arise, but should be watched. Suggestions for new features or changes in their input and output mechanisms are welcome. |
Usage
| This module is invoked by {{NUMBEROFSECTIONS}} and may be expanded to include any other NUMBEROFthings. |
sections{{ #invoke:NUMBEROF | sections | page name [ # page name [ # ... ] ] | level = section level number(s) }}- Multiple page names (at least one required) are the
#delimited names of any Wikipedia pages (including namespaces). - section level(s) (required) is any group of numerals between 1 and 6 (inclusive) e.g.
435or5 3 4equates to:
- sections with a level
3( "===" ),4( "====" ) or5( "=====" ) heading.
- sections with a level
- Multiple page names (at least one required) are the
{{#invoke:NUMBEROF|sections|Wikipedia:Village pump (technical)|level=2}}producesTemplate:NUMBEROFSECTIONS{{#invoke:NUMBEROF|sections|Wikipedia:Village pump (technical)#Wikipedia:Village pump (proposals)|level=2}}producesTemplate:NUMBEROFSECTIONS