imported>76561198045853337 (add edit/view links) |
m (1 revision imported: New Files) |
||
(One intermediate revision by the same user not shown) | |||
Line 1: | Line 1: | ||
<includeonly> | <includeonly>{{#invoke:Documentation|doc}}__NOEDITSECTION__{{#seo: | ||
|type = website | |||
|description = {{FULLPAGENAME}} is a template page used on the Star Citizen Wiki. Templates are pages that are embedded (transcluded) into other pages to allow for the repetition of information. | |||
|site_name = Star Citizen Wiki | |||
|locale = {{PAGELANGUAGE}} | |||
}}</includeonly><noinclude>{{/doc}}</noinclude> | |||
{{ | |||
</noinclude> |
Latest revision as of 11:54, 24 March 2024
- Description
- This template is used to insert documentation on template pages.
- Syntax and Parameters
- Type
<noinclude>{{t|documentation|<var>{{FULLPAGENAME}}/doc</var>}}</noinclude>
at the end of the template page. Include the full (exact, including namespace) name of the documentation page as a parameter where possible.
General usage
On the Template page
You should attach <noinclude>{{t|documentation|{{subst:FULLPAGENAME}}/doc}}</noinclude>
to the end of the template page, so it looks like the below:
<includeonly> TEMPLATE CODE HERE Any categories to be inserted into articles by the template</includeonly><noinclude> {{documentation|{{subst:FULLPAGENAME}}/doc}}</noinclude>
This will fill in and add the documentation template to the template-page, but not pages where the template is used due to the inclusion tags. The subst:FULLPAGENAME serves as a wikimedia "Magic Word" and will be replaced by the wikispace and page name once the edit is completed, and serves to direct the template towards the appropriate page for substitution in case the automatic code fails to work.
On the Template/doc page
You should fill this out with information on how to use the template. For example,
- See also Template:Documentation/preload
;Description :This template is used to do something. ;Syntax :Type <code>{{t|templatename}}</code> somewhere. ;Sample output :<code><nowiki>{{templatename|foo}}</nowiki></code> gives... :{{templatename|foo}} <includeonly>Any categories for the template itself</includeonly><noinclude>[[Category:Template documentation|{{PAGENAME}}]]</noinclude>
Use any or all of the above description/syntax/sample output sections. You may also want to add "see also" or further usage information sections.
Note that the above example also uses {{T}} to display the formatting of the template code, without actually calling the template for transclusion (as normally happens with the squiggly brackets).