Wikimedia/Templates

Templates are automatically generated text boxes which pipe user-entered data in a nice format which may also include a small graphic element. By typing a shortcut an editor can create a prefabricated presentation which permits a better user experience for viewers (end-users) who are not editing.

Templates in Wikimedia belong in the Template namespace. In a page, a template is surrounded by braces, such as. The need to type in  is negated, because the braces defaults to the Template namespace unless specified.

Templates can be displayed in two ways. You can either transclude them or substitute them. Normally, a template is transcluded, which shows the version on the original page. If the source page is updated, the template is updated. Substitution copies over the source code of a page as it is. Instead of viewing a page with the parameters specified, it directly pastes the code for the template into the page. The substituted code does not change if the source page changes.

To specify parameters in a template, you use the symbol. This separates the template name/another parameter from the current parameter. Normally, you have to name the given parameter. For example, if  requires a name, then you will have to specify a name by using a parameter, such as. If no name is specified, then  is the same as.