Skip to:
Content
Pages
Categories
Search
Top
Bottom

Remove menu from admin bar


  • Roger Coathup
    Participant

    @rogercoathup

    I’m trying to remove the visit menu from the admin bar.

    I checked out Burt’s FAQ article, and added the following line to my bp_custom.php:

    remove_action( ‘bp_adminbar_menus’, ‘bp_adminbar_random_menu’, 100 );

    Unfortunately, it’s having no effect.

    Am I missing something obvious, how do I remove menus?

Viewing 4 replies - 1 through 4 (of 4 total)

  • Roger Coathup
    Participant

    @rogercoathup

    Ok, dug a little further, the remove_action needed to be called after the bp plugins had loaded.

    So, the solution is:

    function modify_adminbar(){

    remove_action( ‘bp_adminbar_menus’, ‘bp_adminbar_random_menu’, 100 );

    }

    add_action(‘plugins_loaded’,’modify_adminbar’,99);

    Or for a low-tech non-destructive solution add this to custom.css:

    #bp-adminbar-visitrandom-menu {display: none;}


    elemsee
    Participant

    @elemsee

    David, definitely sounds easier.

    I edited and uploaded custom.css to /wp-content/bp-themes/bpmember/css, but doesn’t the custom style sheet need to be called into the template? Simply uploading the file doesn’t seem to do the trick.


    elemsee
    Participant

    @elemsee

    Actually, it’s disappeared on BP, just not on my blog pages

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Remove menu from admin bar’ is closed to new replies.
Skip to toolbar