WordPress at a glance

get_users() WP 1.0

Retrieve list of users matching criteria.

Is the basis for: wp_dropdown_users()

No Hooks.


Array. List of users.


get_users( $args );
Arguments to retrieve users. See WP_User_Query::prepare_query(). for more information on accepted arguments.
Default: array()

Code of get users: wp-includes/user.php WP 5.2.1

function get_users( $args = array() ) {

	$args                = wp_parse_args( $args );
	$args['count_total'] = false;

	$user_search = new WP_User_Query( $args );

	return (array) $user_search->get_results();

Related Functions

From tag: Users (_user)

More from category: Other

No comments
    Hello, !     Log In . Register