Skip to:
Content
Pages
Categories
Search
Top
Bottom

Re: how disable buddypress header menus from main site in wordpress network mode?


doctorproctor
Participant

@doctorproctor

To diagnose the problem, I edited the code recommended in http://buddydev.com/buddypress/remove-buddypress-admin-bar-from-all-blog-except-the-main-buddypress-site/ by using a literal, i.e. replacing

`if($current_site->blog_id!=BP_ROOT_BLOG)`

with

`if($current_site->blog_id==n)`

With n = 1 (the main site, where I don’t want BuddyPress admin bar), the admin bar is disabled from *both* this site and the BuddyPress site (blog 2); with n = 2 (the BuddyPress blog), the admin bar is enabled for both!

This has confirmed that, in my installation, $current_site->blog_id is stuck at 1 no matter whether I’m on the main site or the BuddyPress subdirectory.

Again, I suspect my BuddyPress secondary blog installation is not working correctly, which may explain the above, but ideas quite welcome!

Skip to toolbar