learndash_get_users_for_course( int $course_id, array $query_args = array(), boolean $exclude_admin = true )
Gets the list of users who has access to the given course.
Description #
Parameters #
- $course_id
-
(int) (Optional) The ID of the course. Default 0.
- $query_args
-
(array) (Optional) An array of
WP_User_query
arguments.Default value: array()
- $exclude_admin
-
(boolean) (Optional) Whether to exclude admins from the user list.
Default value: true
Return #
(WP_User_Query) The WP_User_Query
object.
Source #
Changelog #
Version | Description |
---|---|
2.3.0 | Introduced. |