Styling the Second Level Parent using Menu Manager [SOLVED]
Posted: Tue Mar 17, 2009 5:25 pm
Hi,
I'm using CMSMS 1.5.3 and I'm having real trouble trying to style a second level parent item differently from a top level parent item. I've lookes through all the forums and can't work out if i need to have two separate menu templates or if my menumanager logic is just wrong.
I currently have 3 menu levels something like the following
1
2
..2.2
..2.3
....2.3.1
3
4
The problem i have is when i click on the 3rd level menu item (2.3.1 above) it's parent item (2.3) is then styled the same as the top level parent item (2), it is acquiring the "menuparent menuactive" class . Instead i want level 2.3 to be styled just the same as the other second level items eg 2.2. I can't work out how to prevent all parent items at any level from acquiring the "menuparent menuactive" class.
Below is my menu manager logic.
{if $node->parent == true or ($node->current == true and $node->haschildren == true) and $node->depth current == true and $node->depth == '2'}
current == true and $node->depth == '3'}
type == 'sectionheader'}
{$node->menutext}
{elseif $node->type == 'separator'}
{elseif $node->depth == '1'}
depth == '3'}
<a class="subl1"
{/if}
And here is what i currently have:
http://www.russtechrambles.co.uk/how-cmsms-works/pages-and-navigation/advisory-committee.php
And this is what i'm trying to achieve (ie the Organisatiation and Governance menu item should be styled the same as Aims and Objectoves):
http://www.mcdconsortium.org/about/advisory.php
I hope i've given enough information. If anyone can help at all i would be very grateful.
Thanks
Russell
I'm using CMSMS 1.5.3 and I'm having real trouble trying to style a second level parent item differently from a top level parent item. I've lookes through all the forums and can't work out if i need to have two separate menu templates or if my menumanager logic is just wrong.
I currently have 3 menu levels something like the following
1
2
..2.2
..2.3
....2.3.1
3
4
The problem i have is when i click on the 3rd level menu item (2.3.1 above) it's parent item (2.3) is then styled the same as the top level parent item (2), it is acquiring the "menuparent menuactive" class . Instead i want level 2.3 to be styled just the same as the other second level items eg 2.2. I can't work out how to prevent all parent items at any level from acquiring the "menuparent menuactive" class.
Below is my menu manager logic.
{if $node->parent == true or ($node->current == true and $node->haschildren == true) and $node->depth current == true and $node->depth == '2'}
current == true and $node->depth == '3'}
type == 'sectionheader'}
{$node->menutext}
{elseif $node->type == 'separator'}
{elseif $node->depth == '1'}
depth == '3'}
<a class="subl1"
{/if}
And here is what i currently have:
http://www.russtechrambles.co.uk/how-cmsms-works/pages-and-navigation/advisory-committee.php
And this is what i'm trying to achieve (ie the Organisatiation and Governance menu item should be styled the same as Aims and Objectoves):
http://www.mcdconsortium.org/about/advisory.php
I hope i've given enough information. If anyone can help at all i would be very grateful.
Thanks
Russell