Toggle menu
15
236
81
27.8K
Kenshi Wiki
Toggle preferences menu
Toggle personal menu
Not logged in
Your IP address will be publicly visible if you make any edits.

Module:IncrementParams/doc: Difference between revisions

From Kenshi Wiki
Prd (talk | contribs)
Created page with "{{module rating|alpha}} This module increments numbered template parameters. This is useful for inserting new rows into infobox templates, and for other similar tasks where renaming many parameters by hand would be tedious. == Usage == Due to the way templates work, you cannot pass template input to this module in the normal way. Instead, you have to edit the module page directly to get the desired result. Please follow the seven steps listed in the module code. Once..."
 
Prd (talk | contribs)
No edit summary
Line 1: Line 1:
{{module rating|alpha}}
{{doc sub}}


This module increments numbered template parameters. This is useful for inserting new rows into infobox templates, and for other similar tasks where renaming many parameters by hand would be tedious.
This module increments numbered template parameters. This is useful for inserting new rows into infobox templates, and for other similar tasks where renaming many parameters by hand would be tedious.
Line 25: Line 25:
* {{tl|Infobox}}
* {{tl|Infobox}}
* {{tl|Sidebar}}
* {{tl|Sidebar}}
<includeonly>
[[Category:Modules]]
</includeonly>
<noinclude>
<noinclude>
[[Category:Module documentation pages]]
[[Category:Module documentation pages]]
</noinclude>
</noinclude>

Revision as of 22:53, 1 March 2025

This module increments numbered template parameters. This is useful for inserting new rows into infobox templates, and for other similar tasks where renaming many parameters by hand would be tedious.

Usage

Due to the way templates work, you cannot pass template input to this module in the normal way. Instead, you have to edit the module page directly to get the desired result. Please follow the seven steps listed in the module code.

Once you have finished editing the module, you can use it on any page, with the code:

{{subst:#invoke:IncrementParams|main}}

You can also view it as pre-formatted text using the pre parameter. Warning - this doesn't work with subst.

{{#invoke:IncrementParams|main|pre=yes}}

Or you can simply copy and paste the code from the following section.

Output

The module currently outputs the following text:

|header4  = Section 1
|label6   = Label A
|data6    = Data A
|label8   = Label C
|data8    = Data C
|header11 = Section 2
|label13  = Label D
|data13   = Data D

See also