Cleaning BuddyPress Activity Streams

BuddyPress.org
BuddyPress activity streams looked too crowded to clients, but I wasn’t able to disable whole activity streams component, because some useful plugins were using it.

So this piece of code could manage all current feeds of activity by type. Commented out types will not show! Also I’m limiting activity items by 8 at the bottom.

// filter activity feeds
function my_bp_activity_types( $retval ) {
// list of all BP activity types - remove or comment those you won't show.
$retval['action'] = array(
'activity_comment',
'activity_update'
/*,
//'created_group',
//'friendship_created',
//'joined_group',
//'last_activity',
//'new_avatar',
//'new_blog_comment',
//'new_blog_post',
//'new_member',
//'updated_profile'
*/
);
// 8 per page
$retval['per_page'] = 8;
return $retval;
}
add_filter( 'bp_after_has_activities_parse_args', 'my_bp_activity_types' );

From BuddyPress forum and codex. Looks better now.

Share:
This entry was posted in WordPress and tagged . Bookmark the permalink.

Leave a Reply

Your email address will not be published. Required fields are marked *