Open main menu

Extension:TopicTags/Template-Span

< Extension:TopicTags

UsageEdit

Insert the following to a page

{{Span|MyClassname|MyIDname}}

This will render as:

<span class="MyClassname" id="MyIDname">

ExplanationEdit

open an HTML span tag, applying parameter 1 as classname and parameter 2 as ID

InstallationEdit

  1. Create page
    WIKI-URL/Template:Span
  2. Paste in the following:
<span class={{{1}}} id={{{2}}}>{{#if: {{{3}}}||</span>}}<noinclude>


NOTE:
If call contains trailing pipe, then span will be closed:


{{Span|MyClass|MyID|}}

->

<span class="MyClass" id="MyID"></span>


Else, span will be left open

{{Span|MyClass|MyID}}

->

<span class="MyClass" id="MyID">


</noinclude>