[Typo3] multilevel tmenu with different startpoint
Rick [Futuros]
typo3 at futuros.nl
Mon Aug 15 11:43:27 CEST 2005
What seemed to be a simple menu is giving me a hard time.
Take the following tree
Root
- page 1
- page 2
- - page 2.1
- page 3
- - page 3.1
- - - page 3.1.1
- - - page 3.1.2
- - page 3.2
- - - page 3.2.1
- - - page 3.2.2
On every page i want to have the page 3 part of the tree as my leftmenu.
This is no problem i realized this with special=directory.
The problem is that i only want to see page3.1 en page3.2 when i'm not on
the pages 3.1 en 3.2 themself. Only when i am on the 3.1 or 3.2 page i want
the menu to be collapsed. But this seems to be impossible with the
special=directory option.
I hope i am wrong because it seems like usefull (necessary) functionality.
---
For who is interested i have found a temp solution to fix it in css (but it
isn't the best way to go).
lib.leftmenu = HMENU
lib.leftmenu {
special = directory
special.value=6
#entryLevel = 1
# Second level menu-object, textual
1 = TMENU
1 {
expAll=1 #!!! expands the entire tree
# Normal state properties
#NO.allWrap = <li> | </li>
NO.wrapItemAndSub =<li> | </li>
NO.stdWrap.htmlSpecialChars = 1
# Enable active state and set properties:
ACT = 1
ACT.wrapItemAndSub =<li class="active"> | </li>
ACT.stdWrap.htmlSpecialChars = 1
wrap =<ul> | </ul>
}
# Third level menu-object, textual
2 = TMENU
2 {
# Normal state properties
NO.allWrap = <li> | </li>
NO.stdWrap.htmlSpecialChars = 1
# Enable active state and set properties:
ACT = 1
ACT.allWrap = <li class="current"> | </li>
ACT.stdWrap.htmlSpecialChars = 1
wrap =<ul> | </ul>
} # Fourth level menu-object, textual
}
The following css will hide and unhide if active.
#leftmenu li ul
{
display:none;
}
#leftmenu li.active ul{
display:block;
}
- Rick -
Futuros - http://www.futuros.nl
More information about the TYPO3-english
mailing list