I'm building a multilevel menu, nothing new there, but i've run into a small challenge.
I test if the selected item is the active item, and if yes, apply .selected css class.
BUT, when i start to click sublevel items (level 2), then the .selected class disappears from my top navigation. I've not had this problem before, and whatever i do i can't seem to figure it out.
TopNavigation class disappears on sublevel items
Hi there
I'm building a multilevel menu, nothing new there, but i've run into a small challenge.
I test if the selected item is the active item, and if yes, apply .selected css class.
BUT, when i start to click sublevel items (level 2), then the .selected class disappears from my top navigation. I've not had this problem before, and whatever i do i can't seem to figure it out.
Xslt for topnavigation:
Xslt for subnavigation:
In your Top Nav change the following
to
Rich
Hi Rich
Thanks for your contribution. Unfortunately your example removes the .selected class of my topnavigation item completely
Ok, found it:
Did the trick
Glad you worked it out :)
I assumed you were using an pre 4.5 version of Umbraco.
Rich
is working on a reply...
This forum is in read-only mode while we transition to the new forum.
You can continue this topic on the new forum by tapping the "Continue discussion" link below.