Skip to:
Content
Pages
Categories
Search
Top
Bottom

how to remove admin bar entirely from site

  • @charlietech

    Participant

    I upgraded to bp 1.6 and the admin bar reappeared on my site. I want to remove the admin bar entirely from my site. whats the easiest way to remove it?

Viewing 9 replies - 1 through 9 (of 9 total)
  • @megainfo

    Participant

    add_filter(‘show_admin_bar’, ‘__return_false’);

    @rodtrent

    Participant

    If you haven’t already, create a bp-custom.php file in the wp-content/plugins directory. Add this to the file:

    <?php
    // hacks and mods will go here

    // disable the WP Toolbar and revert back to the BuddyBar
    add_filter( ‘bp_use_wp_admin_bar’, ‘_return_false’ );

    ?>

    @charlietech

    Participant

    i created a bp-custom.php in the wp-content/ plugin directory. Did i need to put the file anywhere? I added add_filter(‘show_admin_bar’, ‘__return_false’); to and nothing happen.

    @megainfo

    Participant

    add it in your functions.php or bp-custom.php it work for in the two files.

    @mercime

    Participant

    bp-custom.php file must be uploaded at wp-content/plugins/ folder https://codex.buddypress.org/extending-buddypress/bp-custom-php/

    @megainfo

    Participant

    thx @mercime for correction, i thinked is talk about functions.php

    @charlietech

    Participant

    I uploaded the bp-custom.php and added the add_filter code in it and the code appear under the admin bar in black letters. what am I doing wrong?

    @charlietech

    Participant

    do I add the filiter code in function.php or the bp-custom.php? where do i insert the code or does it matter?

    @r-a-y

    Keymaster

    @charlietech – Trying copying the code below:

    `add_filter( ‘show_admin_bar’, ‘__return_false’ );`

    Sometimes quotes get converted into other characters, which is why the code snippet wasn’t working for you.

Viewing 9 replies - 1 through 9 (of 9 total)
  • The topic ‘how to remove admin bar entirely from site’ is closed to new replies.
Skip to toolbar