[TYPO3] HMENU, entryLevel = 1 problem....
Giannis Economou
gecon at di.uoa.gr
Tue Mar 6 02:45:23 CET 2007
Hi...
I'm trying to build 2 menus on a site and I've got a problem.
Please, consider the following structure:
Home
*About
** Events
** Personel
*Links
I have one horizontal menu to show level1 items that is working right.
This menu displays:
About | Links
The code to produce this (correctly behaved) horizontal menu is:
topnavigation = HMENU
topnavigation.special = directory
topnavigation.special.value = {$mainNavRootPagePID}
topnavigation.1 = TMENU
topnavigation.1 {
wrap = <ul id="topNav"> | </ul>
NO.wrapItemAndSub = <li> | </li>
# Enable active state and set properties:
ACT = 1
ACT.wrapItemAndSub = <li id="active"> | </li>
}
I also have a vertical menu that will display all pages under the one
selected by the horizontal menu. Example:
If "About" page is viewed, the vertical menu should have:
* Events
* Personel
The code I'm using for this, is:
mainnav = HMENU
mainnav.special = directory
mainnav.entryLevel = 1
mainnav.1 = TMENU
mainnav.1 {
wrap = <ul class="mainnav1"> | </ul>
noBlur = 1
NO.wrapItemAndSub = <li> | </li>
ACT = 1
ACT.wrapItemAndSub = <li> | </li>
ACT.ATagParams = class="mainnav1-active"
}
mainnav.2 = TMENU
mainnav.2 {
wrap = <ul class="mainnav2"> | </ul>
noBlur = 1
NO...
ACT ...
}
The problem is that when viewing the "Events" or "Personel" page, no
vertical menu (mainnav) is displayed. Empty! No menu items!
When viewing the "About" page I got the correct mainnav (containing:
"Events" and "Personel").
What is would expect is the same menu items on "Events" or "About"
pages, but different active menu items on each page.
If I change the
mainnav.entryLevel =1
line with:
mainnav.special.value = {$mainNavRootPagePID}
though this is not the behavior I want, the mainnav menu is working
right - displaying the correct menu items ("Events" or "About") and
marking as active the right one...
Something to note (but should not be related, I guess): The "Home" page
is of Type: Shortcut in this site. It is a shortcut to the "About" page.
Thank you in advance...
Regards,
Giannis
More information about the TYPO3-english
mailing list