Skip to:
Content
Pages
Categories
Search
Top
Bottom

Re: BuddyPress and Multi-Site issues

Ops – part to site_id should be as follows:

function my_bp_adminbar_authors_menu() {

global $current_blog,$wpdb;

$blog_url = get_blog_option($current_blog->blog_id, 'siteurl' );

$blog_url_pieces = explode("/", $blog_url);

$blog_url = $blog_url_pieces[2];

$site_id = $wpdb->get_var( "SELECT COUNT(*) FROM wp_site WHERE domain='".$blog_url."'");

Skip to toolbar