|  | HTML |  |

|  | Splash! |  |

|  | PostScript |  |

| Template Toolkit Examples: Splash! Library: Set of Tabs |

| tabbox

|  | tabset |  |

tabsbox |

# Set of Tabs

The splash/tabset template generates a set of tabs from the splash/tab template. If there are more tabs in the set than denoted by the 'tab.limit' style value (currently set to 9) then a scrolling tabset is created showing the current selected tab along with the previous and next tabs in the set.

Source #1:

    [%  tabs = [
     	{ link => '#wait',  text => 'Wait'  }
     	{ link => '#meet',  text => 'Meet'  }
     	{ link => '#shade', text => 'Shade' }
        ]
    %]

    [% INCLUDE splash/tabset %]

Output #1:

|  | Wait |  |

|  | Meet |  |

|  | Shade |  |

Source #2:

    [% INCLUDE splash/tabset select=1 %]

Output #2:

|  | Wait |  |

|  | Meet |  |

|  | Shade |  |

Source #3:

    [% INCLUDE splash/tabset select=2 invert=1 %]

Output #3:

|  | Wait |  |

|  | Meet |  |

|  | Shade |  |

Source #4:

    [%  tabs = [ ];
        FOREACH n = [ 1..20 ];
    	tab = { text => "Item $n" };
    	tabs.push(tab);
        END;
    %]

    [% INCLUDE splash/tabset select=5 %]

Output #4:

| Item 4

|  | Item 5 |  |

Item 6 |