ACF_Location_User_Role::get_valuespublicACF 5.9.0

Returns an array of possible values for this rule type.

Method of the class: ACF_Location_User_Role{}

No Hooks.

Returns

Array.

Usage

$ACF_Location_User_Role = new ACF_Location_User_Role();
$ACF_Location_User_Role->get_values( $rule );
$rule(array) (required)
A location rule.

Changelog

Since 5.9.0 Introduced.

ACF_Location_User_Role::get_values() code ACF 6.8.8

public function get_values( $rule ) {
	global $wp_roles;
	return array_merge(
		array(
			'all' => __( 'All', 'acf' ),
		),
		$wp_roles->get_names()
	);
}