Template:Pagename as template/Doc

From PCSAR

(Difference between revisions)
Jump to: navigation, search

Brett Wuth (Talk | contribs)
(New page: {{Template doc|<nowiki>subst=subst:</nowiki>}} produces the name for the current page as if it were to be called as a template name. This template is similar to {{FULLPAGENAME}} except th...)
Next diff →

Current revision

The template {{Pagename as template|subst=subst:}} produces the name for the current page as if it were to be called as a template name.

This template is similar to Template:Pagename as template/Doc except that if the page is

  • in the Template namespace, the namespace is omitted.
  • in the Main namespace, it starts with a colon (:).

It allows the page to be referenced in {{ transclusions }}.

The name always starts with a space, as a workaround to a mediawiki limitation. (See source for details.) This space can normally be ignored or stripped for most uses.

subst 
(optional) fully evaluate during substitution, if called like:
{{subst:pagename as template|subst=subst:}}


You type... You get...
"{{pagename as template}}" 
"Pagename as template/Doc"
Personal tools