Reply To: Sorting activity stream
hi @danbp
Thanks for your reply,
i have tried the with
bp_activity_get_where_conditions
but this filter will return the where conditions used like
array(3) {
["filter_sql"]=>
string(416) "a.user_id IN ( 451,378,213,431,429,414,415,456,452,473,460,458,283,471,383,468,387,454,441,6,384,475,427 ) AND a.component IN ( 'groups' ) AND a.type IN ( 'activity_update' ) AND a.item_id IN ( 1 )"
["spam_sql"]=>
string(13) "a.is_spam = 0"
["excluded_types"]=>
string(34) "a.type NOT IN ('activity_comment')"
}
it will not contain the ‘ORDER BY’ portion of the query, i hope we will get the total query with the
bp_activity_total_activities_sql
filter in ~L, 664, so when we get the entire query we can replace the ‘ORDER BY’ section using string replace, i have tried by using this but i can’t get the query inside the function, do you have any idea how to use this filter ?