See 'WikiDevi' @ the Internet Archive (MW XML, Files, Images)
upgraded MW to 1.30 - maybe things are slightly less broken

Help:Tabs

From WikiDevi
Jump to: navigation, search

Tabs can be provided on your wiki pages using the TabSystem JavaScript script.

How to install[edit]

  1. Copy the code found here to MediaWiki:Common.js on your site.
  2. Copy the code found here to MediaWiki:Common.css on your site.
  3. Done! You can now easily add tabs to your pages.

How to use[edit]

TabSystem relies on you using divs to split up your content. To start the tab section of your page, have a div called <div class="tabcontainer">.

To add a tab, start with <div class="tabbox">. After this, you can add the name of your tab using <div class="tab">Tab name</div>. Follow this with the contents of your tab, then close the div.

A full code example for a five-tabbed page can be seen below. Indentation is included to help make things clear, though isn't required.

<div class="tabcontainer"> 
    <div class="tabbox"> 
        <div class="tab">Tab #1</div>
        Contents of the first tab will go here.
    </div> 
    <div class="tabbox"> 
        <div class="tab">Tab #2</div>
        Contents of the second tab will go here.
    </div> 
    <div class="tabbox"> 
        <div class="tab">Tab #3</div>
        Contents of the third tab will go here.
    </div> 
    <div class="tabbox"> 
        <div class="tab">Tab #4</div>
        Contents of the fourth tab will go here.
    </div> 
    <div class="tabbox"> 
        <div class="tab">Tab #5</div>
        Contents of the fifth tab will go here.
    </div> 
</div>