Difference between revisions of "Template:PropVals"

From Salem Wiki
Jump to: navigation, search
m (removing hardcoded parameter-name in call to PropVals/List)
m (moved sub-wrappers into helper-templates)
Line 1: Line 1:
 
<onlyinclude><!--
 
<onlyinclude><!--
 
--><ul><!--
 
--><ul><!--
-->{{#arraymap:<!--
+
-->{{#arraymap:
-->{{#arraymap:<!--
+
{{PropVals/getGroupedRecords
-->{{#show:<!--
+
|prop={{{prop|RequiresObj}}}
-->{{{page|{{FULLPAGENAME}} }}}<!--
+
|page={{{page|{{FULLPAGENAME}} }}}
-->|?{{{prop|RequiresObj}}}<!--
+
}}
-->|link=none<!--
+
| {{{grpsep|/\}}}
-->|sep={{!}}<!--
+
| x
-->}}{{{grpsep|/\}}}<!--
+
| {{PropVals/List|x}}
-->|{{{grpsep|/\}}}<!--
+
|
-->|x<!--
+
}}<!--
-->|<!--
 
-->{{PropVals/Group<!--
 
-->|x<!--
 
-->|sep={{{sep|;}}}<!--
 
-->|grpsep={{{grpsep|/\}}}<!--
 
-->}}<!--
 
-->|}}<!--
 
-->|{{{grpsep|/\}}}<!--
 
-->|x<!--
 
-->|<!--
 
-->{{PropVals/List<!--
 
-->|x<!--
 
-->}}<!--
 
-->|}}<!--
 
 
--></ul><!--
 
--></ul><!--
 
--></onlyinclude><noinclude>{{documentation}}</noinclude>
 
--></onlyinclude><noinclude>{{documentation}}</noinclude>

Revision as of 21:52, 23 June 2012


    Template documentation (for the template shown above, sometimes hidden or invisible)

    Description

    This is the main-entry-point of a complex template-class
    It is used to automatically list all the values of a property of a page as an un-ordered list.
    This generated-output will be used in {{Infobox}} to automatically show relevant info.
    See these pages for documentation on functions used:
    Other pages with relevant info are:

    Functional logic

    Syntax

    Type the below code somewhere inside {{Infobox}} or a page:
    {{PropVals |prop=RequiresObj |page={{FULLPAGENAME}} |sep={{{sep|;}}} |grpsep={{{grpsep|/\}}} |showamount={{{showamount|no}}} }}

    Examples

    1. {{PropVals|prop=RequiresObj|page=Help:Infobox/testdata|showamount=y}} gives:
      • {{PropVals|prop=RequiresObj|page=Help:Infobox/testdata|showamount=y|debug=y}} gives:

        Sub-templates


        Visit Template:PropVals/doc to edit this text! (How does this work?)