Filters whether to short-circuit performing the query for author post counts.
Parameters
$post_counts
int[]|false- Array of post counts, keyed by author ID.
$parsed_args
array- The arguments passed to wp_list_authors() combined with the defaults.
More Arguments from wp_list_authors( … $args )
Array or string of default arguments.
orderby
stringHow to sort the authors. Accepts'nicename'
,'email'
,'url'
,'registered'
,'user_nicename'
,'user_email'
,'user_url'
,'user_registered'
,'name'
,'display_name'
,'post_count'
,'ID'
,'meta_value'
,'user_login'
. Default'name'
.order
stringSorting direction for $orderby. Accepts'ASC'
,'DESC'
. Default'ASC'
.number
intMaximum authors to return or display. Default empty (all authors).optioncount
boolShow the count in parenthesis next to the author’s name. Default false.exclude_admin
boolWhether to exclude the'admin'
account, if it exists. Default true.show_fullname
boolWhether to show the author’s full name. Default false.hide_empty
boolWhether to hide any authors with no posts. Default true.feed
stringIf not empty, show a link to the author’s feed and use this text as the alt parameter of the link.feed_image
stringIf not empty, show a link to the author’s feed and use this image URL as clickable anchor.feed_type
stringThe feed type to link to. Possible values include'rss2'
,'atom'
.
Default is the value of get_default_feed() .echo
boolWhether to output the result or instead return it. Default true.style
stringIf'list'
, each author is wrapped in an<li>
element, otherwise the authors will be separated by commas.html
boolWhether to list the items in HTML form or plaintext. Default true.exclude
int[]|stringArray or comma/space-separated list of author IDs to exclude.include
int[]|stringArray or comma/space-separated list of author IDs to include.
Source
$post_counts = apply_filters( 'pre_wp_list_authors_post_counts_query', false, $parsed_args );
Changelog
Version | Description |
---|---|
6.1.0 | Introduced. |
User Contributed Notes
You must log in before being able to contribute a note or feedback.