Skip to:
Content
Pages
Categories
Search
Top
Bottom

Re: @Mods: Remove bp_core_admin_bar_css on Backend


21cdb
Participant

@21cdb

Hey r-a-y

thanks again for your help, but that doesn’t work neither.

I tried it with remove_action(‘wp_head‘, ‘bp_core_admin_bar_css’, 1);

and also with remove_action(‘admin_head‘, ‘bp_core_admin_bar_css’, 1);

I had a look at bp-core-cssjs.php and on line 108 i found the following function

/**
* bp_core_add_admin_css()
*
* Add the CSS needed for all components in the admin area.
*
* @package BuddyPress Core
* @uses get_option() Selects a site setting from the DB.
*/
function bp_core_add_admin_css() {
if ( defined( 'BP_DISABLE_ADMIN_BAR') )
return false;

wp_enqueue_style( 'bp-admin-bar', apply_filters( 'bp_core_admin_bar_css', BP_PLUGIN_URL . '/bp-core/css/admin-bar.css' ) );
}
add_action( 'admin_menu', 'bp_core_add_admin_css' );

It seems to be the key to remove the admin-bar.css on the backend of WPMU. However i tried it with the following code, but it still doesn’t work.

function remove_adminbar_css(){
remove_action('admin_menu', 'bp_core_add_admin_css', 1);
}
add_action('plugins_loaded','remove_adminbar_css');

Skip to toolbar