BuddyBoss Home – Web › Support Forums › Plugins › BuddyBoss Wall › display_comments=stream not working after installing plugin
Tagged: comment stream
- This topic has 3 replies, 2 contibutors, and was last updated 9 years, 1 months ago by Anonymous.
Viewing 4 posts - 1 through 4 (of 4 total)
Question
October 9, 2015 at 12:18 pm #48331Answers
October 10, 2015 at 10:39 pm #48412@
AnonymousHi @maddish , Wall plugin regenerate the activity on the basis of Wall and NewsFeed parameters
Following function will give you an idea how to modify Wall activity
you can use them inside the child theme functions.phpfunction filter_wall_where(){ global $bp; $user_id = $bp->displayed_user->id; $table = bp_core_get_table_prefix() . 'bp_activity'; $where = "WHERE ( $table.user_id = $user_id AND $table.type = 'activity_update' )"; return $where; } function filter_wall_mentions(){ global $bp; $user_id = $bp->displayed_user->id; $user_filter = $bp->displayed_user->domain; $table = bp_core_get_table_prefix() . 'bp_activity'; $mentions_modifier = "OR ( $table.content LIKE '%$user_filter%' AND $table.type = 'activity_update' ) "; return $mentions_modifier; } add_filter('buddyboss_wall_query_wall_activity_ids_where', 'filter_wall_where'); add_filter('buddyboss_wall_query_wall_activity_ids_mentions', 'filter_wall_mentions'); function filter_wall_feed_where(){ global $bp; $user_id = $bp->displayed_user->id; if ( function_exists( 'friends_get_friend_user_ids' ) ) { $user_ids = friends_get_friend_user_ids( $user_id, false, false ); } else { $user_ids = array(); } $user_list = implode( ',', $user_ids ); if ( empty( $user_list ) ) { $user_list = 0; } $table = bp_core_get_table_prefix() . 'bp_activity'; $where = "WHERE ( $table.user_id IN ($user_list) AND $table.type = 'activity_update' )"; return $where; } add_filter('buddyboss_wall_query_feed_activity_ids_where', 'filter_wall_feed_where');
Regards
Varun DubeyOctober 11, 2015 at 6:41 am #48450@maddishHi @vapvarun
Thank you for your answer.It works …right what I needed.
Thanks a lot
Maddish
October 13, 2015 at 12:54 pm #48658@
Anonymous🙂 Glad to help
Regards
Varun Dubey
Viewing 4 posts - 1 through 4 (of 4 total)
- The question ‘display_comments=stream not working after installing plugin’ is closed to new replies.