BP_Blogs_Blog::exists()
Check whether an association between this user and this blog exists.
Description Description
Return Return
(int) $value The number of associations between the user and blog saved in the blog component tables.
Source Source
File: bp-blogs/classes/class-bp-blogs-blog.php
public function exists() { global $wpdb; $bp = buddypress(); return $wpdb->get_var( $wpdb->prepare( "SELECT COUNT(id) FROM {$bp->blogs->table_name} WHERE user_id = %d AND blog_id = %d", $this->user_id, $this->blog_id ) ); }