bp_activity_get_comments_user_ids()
Return the IDs of every user who’s left a comment on the current activity item.
Description
Return
(bool|array) An array of IDs, or false if none are found.
Source
File: bp-activity/bp-activity-template.php
3431 3432 3433 3434 3435 3436 3437 3438 3439 3440 3441 3442 3443 3444 3445 3446 | function bp_activity_get_comments_user_ids() { global $activities_template ; $user_ids = ! empty ( $activities_template ->activity->children ) ? ( array ) bp_activity_recurse_comments_user_ids( $activities_template ->activity->children ) : array (); /** * Filters the list of user IDs for the current activity item. * * @since BuddyPress 1.7.0 * * @param array $value Array of unique user IDs for the current activity item. */ return apply_filters( 'bp_activity_get_comments_user_ids' , array_unique ( $user_ids ) ); } |
Changelog
Version | Description |
---|---|
BuddyPress 1.7.0 | Introduced. |
Questions?
We're always happy to help with code or other questions you might have! Search our developer docs, contact support, or connect with our sales team.