Loops - fornumargs

From Semantic MediaWiki - Sandbox

Syntax of template "LoopsFornumargs"
{{#fornumargs: number
 | value
 | <nowiki />
* {{#var: number }} = {{#var: value }}
}}
Syntax of template usage on a page
{{LoopsFornumargs
 |Apricot
 |B=Bolognese
 |Caramel slice
 |5=Eclair
}}
Result

  • 1 = Apricot
  • 2 = Caramel slice
  • 5 = Eclair


This example makes use of the "Variables" extension.
Cookies help us deliver our services. By using our services, you agree to our use of cookies.