From The Mana World
Revision as of 10:50, 10 March 2015 by Cassy (talk | contribs) (first step, taking a break now and continuing later)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)



Construction-worker.png
This article is currently under construction.
This page will shortly explain what templates are, how to use them, how to find them and how to categorize them.



Description

A template is a wiki page created to be included in other pages. Templates usually contain repetitive material that might need to show up on any number of articles or pages. They are commonly used for boilerplate messages, standard warnings or notices, infoboxes, navigational boxes, and similar purposes.


Usage

Existing templates can be used by adding them with {{Template name}}. For instance {{i18n}} which is the language selection template at the top of this page.

If you want to place a link to a template this works just like other wiki links. Remember to include "Template:". Using the language selection template as example again this would make [[Template:i18n]] -> Template:i18n.


Template categories

Our Wiki keeps categories short and simple. We only use a few categories. If you create a new template please always categorize it the same way.


Creating a template

follows


Translating templates

Most templates are translatable within the original template, meaning you can put translations in the source of them instead of creating a new translated template page. "#switch: {{NAMESPACE}}" allows to create a switch. Depending on which translation page you are at {{NAMESPACE}} will display the corresponding content. The source looks like this:

{{switch: {{NAMESPACE}} | De = German translation | Es = Spanish translation | Fr = French translation | Zh = Chinese translation | #default = Original English text }}

So when you are at the German (De) translation page using a template with this source, it will say "German translation". On the Spanish (Es) translation page it will say "Spanish translation" and so on. You might want to check other templates to understand better. See Category Translation Template.


However, not every template is translatable in this fashion. Those need new translated templates, just like translation pages. Please name them like this:

"Template:.Fr:Template name", for usage it's "{{.Fr:Template name}}".


See also