Support » Plugin: Advanced Sidebar Menu » Highlighting current level 2 page and parent but not siblings …

  • Resolved M One

    (@m-one)


    Wonder if you could help me with most efficient css for this. I’m using background color to create a button menu with a hover color and active color.

    .advanced-sidebar-menu li.current_page_item a – lets me highlight the current page but when this is a parent with sub pages it also highlights all the children of the current parent page.

    The functionality I am after is – when the parent page is active it is highlighted and the children are displayed but are not highlighted.

    When a child page is active both it and its parent are highlighted but its inactive siblings are not.

    I’m getting there but feels like I’m kludging so wonder if you could point me in the right direction?

    Many Thanks.

    http://wordpress.org/plugins/advanced-sidebar-menu/

Viewing 1 replies (of 1 total)
  • Plugin Author Mat Lipe

    (@mat-lipe)

    Hi M One,

    You could try adjusting your CSS to something like this:

    .advanced-sidebar-menu li.current_page_item > a

    .advanced-sidebar-menu li.current_page_ancestor > a

    This should target only the levels you would like and no sub levels.

    Hope this helps!

Viewing 1 replies (of 1 total)
  • The topic ‘Highlighting current level 2 page and parent but not siblings …’ is closed to new replies.