Skip to:
Content
Pages
Categories
Search
Top
Bottom

How to filter “All Members” count on activity stream page


  • John
    Participant

    @johnmcole

    I’m filtering the activity stream to only reflect friends/BuddyPress members (along with only new topics and replies) as follows:

    /* Filter Activity Stream to only display new topics and replies */
    function gk_filtering_activity_default( $query ) {
    if ( empty( $query ) && empty( $_POST ) ) {
    $query = ‘action=bbp_topic_create,bbp_reply_create&scope=friends’;
    }
    return $query;
    }
    add_filter( ‘bp_ajax_querystring’, ‘gk_filtering_activity_default’, 999 );

    However, I’m still seeing the members count in the “All Members” tab showing all users in the system, rather than just friends/BP members.

    Is there a recommended approach for filtering that number in the same way? I found the ‘bp_get_total_member_count’ filter, but I’m not finding a clear path for getting the right count.

    Thanks,
    John

  • You must be logged in to reply to this topic.
Skip to toolbar