| ||
![]() |
Multiple Levels of Tabs | |
|
This Navigation Element simulates the normal menu using tabs, showing all menu items at every level above the current document.
To use: 1. Download tabsall.xsl and tabsall.css 2. Place tabsall.xsl in either: apache-lenya-1.2.2/build/lenya/webapp/lenya/xslt/navigation (for global use)
{pub}\lenya\xslt\navigation (for a single publication)
3. Edit {pub}/publication-sitemap.xmap, and add the navigation element: AFTER: <map:part src="cocoon://navigation/{2}/{3}/tabs/{5}.xml"/>
ADD: <map:part src="cocoon://navigation/{2}/{3}/tabsall/{5}.xml"/>
4. Edit {pub}/xslt/page2xhtml.xsl ADD: <xsl:apply-templates select="xhtml:div[@id = 'tabsall']"/>
where you want the tabs to appear, probably replacing: <xsl:apply-templates select="xhtml:div[@id = 'tabs']"/>
The file must include the default "copy everything not specified" match: <xsl:template match="@*|node()" priority="-1">
If that has been removed, use a mode to apply it just to this. 5. Add the CSS from tabsall.css to your website. You can either: A. Add the contents of tabsall.css to {pub}/resources/shared/css/page.css, or
B. Place tabsall.css in {pub}/resources/shared/css/ and add the following line to your HTML in page2xhtml.xsl:
<link rel="stylesheet" href="{$root}/css/tabsall.css" type="text/css"/>
Then adjust the CSS to fit your website. Please send any suggestions to the Lenya User Mailing List.
|