Codex tools: Log in
Languages: English • 日本語 • Türkçe • (Add your language)
Contents |
Create dropdown HTML content of users.
<?php wp_dropdown_users( $args ); ?>
<?php $args = array(
'show_option_all' => null, // string
'show_option_none' => null, // string
'hide_if_only_one_author' => null, // string
'orderby' => 'display_name',
'order' => 'ASC',
'include' => null, // string
'exclude' => null, // string
'multi' => false,
'show' => 'display_name',
'echo' => true,
'selected' => false,
'include_selected' => false,
'name' => 'user', // string
'id' => null, // integer
'class' => null, // string
'blog_id' => $GLOBALS['blog_id'],
'who' => null // string
); ?>
Displays a users dropdown list in HTML form with a submit button.
<li id="users">
<h2><?php _e('users:'); ?></h2>
<form action="<?php bloginfo('url'); ?>" method="get">
<?php wp_dropdown_users(array('name' => 'author')); ?>
<input type="submit" name="submit" value="view" />
</form>
</li>
Since: 2.3.0
wp_dropdown_users() is located in wp-includes/user.php.
wp_list_authors(), wp_list_categories(), wp_list_pages(), wp_list_bookmarks(), wp_list_comments(), wp_get_archives(), wp_page_menu(), wp_dropdown_pages(), wp_dropdown_categories(), wp_dropdown_users()