WordPress.org

Ready to get started?Download WordPress

Codex

Attention Interested in functions, hooks, classes, or methods? Check out the new WordPress Code Reference!

Function Reference/list authors


This function has been deprecated. That means it has been replaced by a new function or is no longer supported, and may be removed from future versions. All code that uses this function should be converted to use its replacement if one exists. See also wp-includes/deprecated.php. Use any of these functions instead.

Contents

Description

Displays a list of the authors on a blog, and if desired, other information such as a link to each author's RSS feed.

Replace With

Usage

 <?php list_authors$optioncount$exclude_admin$show_fullname,
                        
$hide_empty$feed$feed_image ); ?> 

Parameters

optioncount 
(boolean) Display number of posts by each author. Options are:
  • TRUE
  • FALSE (Default)
exclude_admin 
(boolean) Exclude the administrator account from authors list. Options are:
  • TRUE (Default)
  • FALSE
show_fullname 
(boolean) Display the full (first and last) name of the authors. Options are:
  • TRUE
  • FALSE (Default)
hide_empty 
(boolean) Do not display authors with 0 posts. Options are:
  • TRUE (Default)
  • FALSE
feed 
(string) Text to display for a link to each author's RSS feed. Default is no text, and no feed displayed.
feed_image 
(string) Path/filename for a graphic. This acts as a link to each author's RSS feed, and overrides the feed parameter.

Examples

Default Usage

Display the list of authors using default settings.

<?php list_authors(); ?>

Authors with Number of Posts

This example causes the site's authors to display with the number of posts written by each author, excludes the admin author, and displays each author's full name (first and last name).

<?php list_authors(TRUE, TRUE, TRUE); ?>
Harriett Smith (42)

Sally Smith (29)

Andrew Anderson (48)

Full Name and Authors With No Posts Usage

Displays the site's authors without displaying the number of posts, does not exclude the admin, shows the full name of the authors, and does not hide authors with no posts. It does not display the RSS feed or image.

<?php list_authors(FALSE, FALSE, TRUE, FALSE); ?>

Change Log

Related

the_author(), get_the_author(), the_author_link(), get_the_author_link(), the_author_meta(), get_the_author_meta(), the_author_posts(), get_the_author_posts(), the_author_posts_link(), get_author_posts_url(), get_the_modified_author(), the_modified_author(), wp_dropdown_users(), wp_list_authors()

See also index of Function Reference and index of Template Tags.