Difference between revisions of "Template:SplitCategory/doc"

From OpenMedia
Jump to: navigation, search
m (+docu)
 
m (added print replacement)
Line 3: Line 3:
 
=== Usage ===
 
=== Usage ===
  
 +
The {{#titleparts:  {{FULLPAGENAME}}| 1 }} assumes to get a colon-separeted input like:
 
  <nowiki>{{SplitCategory|one, two, three}}</nowiki>
 
  <nowiki>{{SplitCategory|one, two, three}}</nowiki>
…creates dependending on the language…
+
…and creates categories dependending on the language…
 
  <nowiki>[[Category:one]] [[Category:two]] [[Category:three]] </nowiki>
 
  <nowiki>[[Category:one]] [[Category:two]] [[Category:three]] </nowiki>
  
 
If “<code>print = true</code>”…
 
If “<code>print = true</code>”…
  <nowiki>{{SplitCategory|one, two, three|print=true}}</nowiki>
+
  <nowiki>{{SplitCategory | one, two, three | print=true}}</nowiki>
 
…“one, two, three” is printed additionally right where the template is used.
 
…“one, two, three” is printed additionally right where the template is used.
 +
 +
If just “<code>replace sep for print = ,• </code>” is specified
 +
<nowiki>{{SplitCategory | one, two, three | replace sep for print = ,• }}</nowiki>
 +
…a replacment is done and it looks nicely like “one&nbsp;• two&nbsp;• three” …;-)
 +
 +
 
=== See also ===
 
=== See also ===
  

Revision as of 17:54, 5 February 2010

This is a documentation subpage for Template:SplitCategory (see that page for the template itself).
It contains usage information, categories and other content that is not part of the original template page.

Usage

The Template:SplitCategory assumes to get a colon-separeted input like:

{{SplitCategory|one, two, three}}

…and creates categories dependending on the language…

[[Category:one]] [[Category:two]] [[Category:three]] 

If “print = true”…

{{SplitCategory | one, two, three | print=true}}

…“one, two, three” is printed additionally right where the template is used.

If just “replace sep for print = ,• ” is specified

{{SplitCategory | one, two, three | replace sep for print = ,• }}

…a replacment is done and it looks nicely like “one • two • three” …;-)


See also