Jump to content

Template:Always substitute/doc

From FeministWiki
Revision as of 17:51, 22 September 2026 by Minervaproject (talk | contribs) (Created page with "{{doc sub}} <!--- PLEASE ADD CATEGORIES WHERE INDICATED AT THE BOTTOM OF THIS PAGE ---> {{lua|Module:Unsubst}} {{Always substitute|yesnomaybe=never}} {{tsh|subst only|substed|substitute|substituted|substonly|clear=right}} {{high-use}} {{tlf|Always substitute|code=on}} produces the following notice: {{quote|{{Subst only|actualtemplate={{tlg|foo|subst=on}}|nocat=true}}}} (but the {{tlf|Always substitute}} template itself should {{em|{{strong|never}}}} be Help:Substitutio...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

Template:Doc sub Script error: No such module "Lua banner". Script error: No such module "Unsubst". Script error: No such module "Shortcut". Script error: No such module "High-use". Script error: No such module "Template link general". produces the following notice:

<templatestyles src="Template:Blockquote/styles.css" />

Script error: No such module "Unsubst".

Script error: No such module "Check for unknown parameters".

(but the Script error: No such module "Template link general". template itself should never be substituted.)

Usage

{{Always substitute}}

Script error: No such module "Template link general". should be placed on the documentation subpage of any template that requires substitution rather than transclusion (not on the template's own page itself).

Parameters

All of the parameters for this template are optional. If none of the parameters are used when transclusing this template onto the documentation subpage of a template, it will default to displaying a notice stating that the template "should always be substituted", and include a statement with the template syntax that the reader should always use in order to substitute it onto a page. No additional statements are amended to the notice, and automatic categorization of the template that this notice refers to is allowed.

|yesnomaybe=
Can be set to never, not, can, may, or always.
  • Setting it to never or not will display a notice stating that the template "should never be substituted" or "should not be substituted", respectively – and display the template syntax that the reader should always use in order to transclude it onto a page.
  • Setting it to can or may will display a notice stating that the template "can be substituted" or "may be substituted", respectively – and display the template syntax that the reader can use in order to substitute it onto a page if they so choose.
  • Setting it to always will display a notice stating that the template "should always be substituted" – and display the template syntax that the reader should always use in order to substitute it onto a page.
If this parameter is not used, or if it is set to anything not listed above, the template defaults to using always.
|auto=yes
Set this parameter to yes if a Wikipedia bot automatically searches for accidental transclusions of the template this notice refers to and fixes them to be substitutions, unless the |demo=yes parameter is set.
If this parameter is not used, or if it is set to anything other than yes,[1] the template defaults to using no.
|alt=
Set this parameter to the page title or location of an alternate template that the reader should use for transclusion instead of the template that the notice refers to (e.g. |alt=Template:Example or |alt=Example).
  • Enter the page title or location using plain text, and do not include quotations, square brackets, or braces.
  • When set to a page title or location, the notice will include a statement instructing the reader to use the alternate template for transclusions, and provide the appropriate template syntax for the reader to use.
  • If the location includes "Template:" or "TM:" at the beginning of the text, it is automatically dropped from being displayed in the template syntax.
  • This parameter is ignored by the template if |yesnomaybe= is set to an option other than always, since this would cause the template to show conflicting information to the reader that makes no sense.
If this parameter is not used, or if it is set to no value or to only whitespace characters, the template will default to not displaying the additional information to the reader.
|nocat=true
Set this parameter to true in order to suppress automatic categorization of the template that it applies to.
If this parameter is not used, or if it is set to anything other than yes,[1] the template defaults to allowing automatic categorization.

Categorization

Pages that include Script error: No such module "Template link general". are added to Category:Wikipedia substituted templates.

Templates that subst a template name string onto the target page in hidden text are added to Category:Templates with matching hidden id if and only if the hidden template name string matches the name of the template. For example: Template:Uw-coi contains the token <!-- Template:Uw-coi -->, and since the token matches the Template name, Template:Uw-coi is a member of the category.

Template:List of subst helper templates


Notes

<templatestyles src="Reflist/styles.css" />

  1. ↑ 1.0 1.1 This template uses {{yesno-no}} to sanitize and parse the input so that the result is either yes or no. As a result, setting this parameter to any input that is construed to be affirmative will also return yes. See template documentation for more information.

Script error: No such module "Check for unknown parameters".