WordPress.org

Forums

Dynamic Menu Highlighting with WP 3 Menus (3 posts)

  1. Connor Crosby
    Member
    Posted 4 years ago #

    Hello,

    I was following the instructions on how to make a dynamic menu highlight using method 2: http://codex.wordpress.org/Dynamic_Menu_Highlighting and I was wondering how I could do this when using the menu feature in WordPress? For example, if I were to enter my menu items in the WordPress dashboard, how could I still add an id of "current" for the menu item currently selected?

    Thanks,
    Connor

  2. Josh Betz
    Member
    Posted 4 years ago #

    You wouldn't add an id of current. In WordPress the current menu item has a class of .current_menu_item

    If you've already got your CSS written, you can just replace #current with .current_menu_item

  3. Connor Crosby
    Member
    Posted 4 years ago #

    Oh really? Thanks for the tip!

Topic Closed

This topic has been closed to new replies.

About this Topic