From Moped Wiki
Jump to: navigation, search

Templates are standard texts that can be easily included on many pages. Benefits of using templates include:

  • you don't have to copy and past the same text onto every page
  • if you want to change what the template says, you only have to change it in one place (the template's page) rather than on every page the template is copied onto
  • templates make the editable version of the page neater-looking and less confusing for beginning editors
  • templates can be used to include all the pages with that template into a certain category

Creating a Template

Templates must be prefixed with Template, and you create them like any other wiki page.

For example, you could use any of the normal article-creation methods to create the page Template:Really awesome template, which would allow you to make a template with the name Really awesome template.

Using a Template

Templates are wiki pages which are typically used in the following way:

{{Template name}} includes the current content of the page [[Template:Template name]] in the article being edited.

Common templates include:

  • the Stub template, which adds the message "This article is a stub. You can help the Moped Wiki by expanding it" message to the page
  • the TOCright template, which moves the table of contents to the right side of the page

A list of all templates can be found at the all pages template namespace.

Control Template Inclusion

You can control template inclusion by the use of <noinclude> and <includeonly> tags.


Anything between <noinclude> and </noinclude> will be processed and displayed only when the template page is being viewed directly; it will not be included in the template itself.

Possible applications are:

  • Categorizing templates
  • Explanatory text about how to use the template (always a plus when this is included)

An example of these tags can be seen on the moped brand template.


The converse is <includeonly>. Text between <includeonly> and </includeonly> will be processed and displayed only when the page is being included. The obvious application is to add all pages containing a given template to a category.

An example of these tags can be seen on the stub template.

Please Note...

That the usual update problems apply -- if you change the categories inside a template, the categories of the referring pages won't be updated until those pages are edited.

Advanced Templates

If the template business listed here isn't fancy enough for you, please see below for some more resources to satiate all your template-related desires.

  • Check here for a good guide on using parameters in templates.
  • The Wikipedia help template page should have enough template information to keep you occupied for the next several months. Enjoy!

MopedWiki Help Pages
IntroductionSearchingBasic EditingEditing (longer)LinksCategories
ImagesTablesTemplatesUserboxesRevertingStubsRainy Day Edits