Function: wp_dropdown_roles

wp_dropdown_roles( string $selected )

Print out option html elements for role selectors.

Parameters

Name Type(s) Default Value Description
$selected string ''

Slug for the role that should be already selected.

WordPress Developer Newsletter

Stay on top of the latest WordPress API changes, developer tool updates, security alerts and more.