Template:Documentation/core: Difference between revisions

From Donate
Jump to navigation Jump to search
Content deleted Content added
imported>Davidgothberg
If "content" fed, don't link the /doc page. (Good thing I do detailed testing.)
imported>Davidgothberg
Revert my last edit and fix some related code: The doc of {{documentation}} shows a case when "content" is fed AND the /doc links are needed. So back to linking the /doc page if it exists.
Line 45: Line 45:
-->{{#if:
-->{{#if:
<!--Check if we need the small box-->
<!--Check if we need the small box-->
{{#if: {{{content|}}}
{{{doc exist|yes}}}{{
#switch: {{SUBJECTSPACE}}
| <!--Don't link the /doc page-->
| {{{doc exist|yes}}}
}}{{#switch: {{SUBJECTSPACE}}
| {{ns:User}}
| {{ns:User}}
| {{ns:Template}} = yes
| {{ns:Template}} = yes
Line 57: Line 55:
| style = background-color: #ecfcf4;
| style = background-color: #ecfcf4;
| text =
| text =
''{{#if: {{{content|}}}
''{{#if: {{{doc exist|yes}}}
| <!--Don't link the /doc page-->
| <!--/doc exists, link to it-->
The above [[Wikipedia:Template documentation|documentation]] is [[Wikipedia:Transclusion|transcluded]] from [[{{{docpage|{{FULLPAGENAME}}/doc}}}]]. <small style="font-style: normal">([{{fullurl:{{{docpage|{{FULLPAGENAME}}/doc}}}|action=edit}} edit] &#124; [{{fullurl:{{{docpage|{{FULLPAGENAME}}/doc}}}|action=history}} history])</small> <br>
| {{#if: {{{doc exist|yes}}}
| <!--/doc exists, link to it-->
The above [[Wikipedia:Template documentation|documentation]] is [[Wikipedia:Transclusion|transcluded]] from [[{{{docpage|{{FULLPAGENAME}}/doc}}}]]. <small style="font-style: normal">([{{fullurl:{{{docpage|{{FULLPAGENAME}}/doc}}}|action=edit}} edit] &#124; [{{fullurl:{{{docpage|{{FULLPAGENAME}}/doc}}}|action=history}} history])</small> <br>
}}
}}<!--
}}<!--
Add links to /sandbox and /testcases when appropriate
Add links to /sandbox and /testcases when appropriate
-->{{#switch: {{SUBJECTSPACE}}
-->{{#switch: {{SUBJECTSPACE}}
| {{ns:User}}
| {{ns:User}}

Revision as of 21:34, 5 February 2010

[edit] [Purge] Template documentation
Template:Documentation/core/doc
The above documentation is transcluded from Template:Documentation/core/doc. (edit | history)
Editors can experiment in this template's sandbox (create) and testcases (create) pages.