Template:Tab view/doc

Description
Tab view provides an easy way to display multiple content pages in a single article using tabs. This can be an attractive and useful view for organizing content.

Step-by-step

 * First, you need to create a page of content for each tab you wish to display. These pages can be created anywhere on your wikia.


 * In this example, we've created two subpages to this article, which we will use in our tabs below. They are titled:
 * Example:Tab view/Sample tab content 1
 * Example:Tab view/Sample tab content 2


 * Open the page that you'd like to display tabs on for editing, and switch to source mode.


 * Enter your tab code in the following format:

PAGENAME1|TITLE1 PAGENAME2|TITLE2

So, in our example here, we'll enter:

Example:Tab view/Sample tab content 1|Tab 1 Example:Tab view/Sample tab content 2|Tab 2

This will give us the following tabs:

Example:Tab view/Sample tab content 1|Tab 1 Example:Tab view/Sample tab content 2|Tab 2

Customization
In addition to the title, there are two other variables you can customize in your tabs:


 * Cache
 * Preset

We'll explain each of these below. They display in this order:

PAGENAME|TITLE|CACHE|PRESET

Disabling tab cache
If a page is showing very frequently updated information, you may want to force the tab to check for new content on each page load. This can be done with a second pipe, followed by the word "false." This should be used sparingly, however, as it can slow down the overall reading experience.

Example:Tab view/Sample tab content 1|Tab 1|false Example:Tab view/Sample tab content 2|Tab 2

Preset an open tab
The last variable chooses which tab is open when the page loads. By default, all tabs are closed, but you can choose an open tab by using a third pipe followed by the word "true":

Example:Tab view/Sample tab content 1|Tab 1 Example:Tab view/Sample tab content 2|Tab 2||true

This will give you:

Example:Tab view/Sample tab content 1|Tab 1 Example:Tab view/Sample tab content 2|Tab 2||true