WordPress.org

Ready to get started?Download WordPress

Forums

Highlight current toolbar item (1 post)

  1. James
    Member
    Posted 2 years ago #

    hi,

    I see a lot of tutorials on how to highlight li and menus, but see nothing regarding wp toolbar (admin bar).

    How do I highlight current toolbar item, if I add it using code below?

    add_action('admin_bar_menu', 'add_menu_items', 1);
    
    function add_menu_items($admin_bar)
    {
    $admin_bar->add_menu( array(
    
    	'id'    => 'home',
    	'title' => 'Home',
    	'href'  => site_url(),
    ) );}

    Is it possible to implement http://codex.wordpress.org/Dynamic_Menu_Highlighting here?

    thank you!

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags