Templates
Templates are a special kind of wiki page that can being included in other pages. Most of them work by a process called "transclusion", which makes them behave like standard computer programming functions: they take an input, manipulate it in some way, and then output the result. You call them like this:
{{TemplateName | Input}}
and when you save the wiki page it comes out like this:
Output
A few special templates, the page templates, work the way something called a "template" sounds like it should work - they create a blank page for you to fill in. You call them like so:
{{subst:TemplateName | Parameter 1 | Parameter 2}}
and then save the page. After you save, the appropriate formatting will be copied and pasted into your page, and when you open it for editing again you can just fill in the blanks.
Utility Templates[edit | edit source]
Utility templates are very simple templates that add basic functionality to the wiki.
Parsers[edit | edit source]
Parsers take some input, look it up in a table, and return the corresponding output. Currently we're mostly using them to match parties/media organisation names to the appropriate infobox colours.
Wrappers[edit | edit source]
Wrappers take some kind of text as an input and return it wrapped in a standard format, like a quotebox.
Infoboxes[edit | edit source]
An infobox is a very specialised sort of wrapper that creates (duh) an infobox.
- Template:Hack Infobox
- Template:Politician Infobox
- Template:Ship Infobox
- Template:Significant Other Infobox
- Template:Spad Infobox
Page Templates[edit | edit source]
Page templates are substituted in to create a whole blank page of a certain type, which can then be filled in.