Skip to:
Content
Pages
Categories
Search
Top
Bottom

Reply To: I've Figured Out How To Create a Facebook-Style Wall, But…

@shanebp

Moderator

Using ‘scope’ will over-ride any filters, as noted in bp-activity-template.

There are various ways to makes this a function, but it depends on your install params, hooks etc.

Following on with your approach, try putting this (untested) at the top of the main activity template.


$user_id = bp_loggedin_user_id();
$following = array();
if ( bp_is_active( 'bp-follow') )
	$following = bp_follow_get_following( array( 'user_id' => $user_id ) );

$friends = array();
if ( bp_is_active( 'friends') )
	$friends = friends_get_friend_user_ids( $user_id );
	
$me = array( $user_id );
$wall = array_merge( $following, $friends, $me );
$wall = array_unique( $wall );
$user_ids = implode( ',', $wall );
$get_users = "'user_id=" . $user_ids . "'"; 

if ( bp_has_activities( $get_users ) )
	//etc
Skip to toolbar