Issue with active menu when it's a category (2 posts)

  1. whoaloic
    Posted 4 years ago #

    I get an issue with my menu items.
    I have both pages and categories in the menu (using wp_nav_menu) but I have trouble when I want to highlight the current categories items.
    What I would like is to have only the parent category highlighted when the user in on this category and not its child.
    Same thing, when an user is on a child category or in a single item of a category, the other childs and the parent are also highlighted!

    I tried current class like "current-page-ancestor" and other but I can't manage to do what I'd like.
    Here's an URL to see what I mean.
    The "portfolio" item of the navigation is a category.

    Please I really need help on it.
    I'm stuck on it for hours.


  2. whoaloic
    Posted 3 years ago #

    Any help would be appreciated!

Topic Closed

This topic has been closed to new replies.

About this Topic