Help:A quick guide to templates: Difference between revisions

Content deleted Content added
m Creating, editing and using templates: italics for the variable name
Creating, editing and using templates: When the template is updated, all pages containing the template tag will automatically be updated.
Line 8:
You start a new template in the same way you would [[Help:Starting a new page|start a normal page]]. The only difference is that its title must start with <tt>Template:</tt>.
 
Once you have made the template, you can add <nowiki>{{</nowiki>''templatename''<nowiki>}}</nowiki> to the pages you want to use it on. Every page using this template will get the same boilerplate text, each time a user visits it. When the template is updated, all pages containing the template tag will automatically be updated.
 
Alternatively, you can add <nowiki>{{</nowiki>subst:''templatename''<nowiki>}}</nowiki> to the pages you want to use the boileplate text on. The system will fetch a one-time copy of the template text and '''substitute''' it into the page, in place of the template tag. If anyone edits the template afterwards, pages that used the <tt>subst:</tt> keyword will '''not be updated'''. Sometimes that's what you want.