Skip to content

Commit 86baf19

Browse files
DrewAPictureDrewAPicture
authored andcommitted
Docs: Reorder argument descriptions in the DocBlock for wp_list_categories() to match the default arguments list and improve reading at a glance.
Props birgire for the initial patch. Fixes #36693. git-svn-id: https://develop.svn.wordpress.org/trunk@37571 602fd350-edb4-49c9-b593-d223f7449a82
1 parent b761a58 commit 86baf19

File tree

1 file changed

+26
-26
lines changed

1 file changed

+26
-26
lines changed

src/wp-includes/category-template.php

Lines changed: 26 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -500,44 +500,44 @@ function wp_dropdown_categories( $args = '' ) {
500500
* @param string|array $args {
501501
* Array of optional arguments.
502502
*
503-
* @type string $show_option_all Text to display for showing all categories. Default empty string.
504-
* @type string $show_option_none Text to display for the 'no categories' option.
505-
* Default 'No categories'.
506-
* @type string $orderby The column to use for ordering categories. Default 'ID'.
507-
* @type string $order Which direction to order categories. Accepts 'ASC' or 'DESC'.
508-
* Default 'ASC'.
509-
* @type bool|int $show_count Whether to show how many posts are in the category. Default 0.
510-
* @type bool|int $hide_empty Whether to hide categories that don't have any posts attached to them.
511-
* Default 1.
512-
* @type bool|int $use_desc_for_title Whether to use the category description as the title attribute.
513-
* Default 1.
514-
* @type string $feed Text to use for the feed link. Default 'Feed for all posts filed
515-
* under [cat name]'.
516-
* @type string $feed_type Feed type. Used to build feed link. See get_term_feed_link().
517-
* Default empty string (default feed).
518-
* @type string $feed_image URL of an image to use for the feed link. Default empty string.
519503
* @type int $child_of Term ID to retrieve child terms of. See get_terms(). Default 0.
504+
* @type int|array $current_category ID of category, or array of IDs of categories, that should get the
505+
* 'current-cat' class. Default 0.
506+
* @type int $depth Category depth. Used for tab indentation. Default 0.
507+
* @type bool|int $echo True to echo markup, false to return it. Default 1.
520508
* @type array|string $exclude Array or comma/space-separated string of term IDs to exclude.
521509
* If `$hierarchical` is true, descendants of `$exclude` terms will also
522510
* be excluded; see `$exclude_tree`. See get_terms().
523511
* Default empty string.
524512
* @type array|string $exclude_tree Array or comma/space-separated string of term IDs to exclude, along
525513
* with their descendants. See get_terms(). Default empty string.
526-
* @type bool|int $echo True to echo markup, false to return it. Default 1.
527-
* @type int|array $current_category ID of category, or array of IDs of categories, that should get the
528-
* 'current-cat' class. Default 0.
529-
* @type bool $hierarchical Whether to include terms that have non-empty descendants.
530-
* See get_terms(). Default true.
531-
* @type string $title_li Text to use for the list title `<li>` element. Pass an empty string
532-
* to disable. Default 'Categories'.
514+
* @type string $feed Text to use for the feed link. Default 'Feed for all posts filed
515+
* under [cat name]'.
516+
* @type string $feed_image URL of an image to use for the feed link. Default empty string.
517+
* @type string $feed_type Feed type. Used to build feed link. See get_term_feed_link().
518+
* Default empty string (default feed).
519+
* @type bool|int $hide_empty Whether to hide categories that don't have any posts attached to them.
520+
* Default 1.
533521
* @type bool $hide_title_if_empty Whether to hide the `$title_li` element if there are no terms in
534522
* the list. Default false (title will always be shown).
535-
* @type int $depth Category depth. Used for tab indentation. Default 0.
536-
* @type string $taxonomy Taxonomy name. Default 'category'.
523+
* @type bool $hierarchical Whether to include terms that have non-empty descendants.
524+
* See get_terms(). Default true.
525+
* @type string $order Which direction to order categories. Accepts 'ASC' or 'DESC'.
526+
* Default 'ASC'.
527+
* @type string $orderby The column to use for ordering categories. Default 'ID'.
528+
* @type string $separator Separator between links. Default '<br />'.
529+
* @type bool|int $show_count Whether to show how many posts are in the category. Default 0.
530+
* @type string $show_option_all Text to display for showing all categories. Default empty string.
531+
* @type string $show_option_none Text to display for the 'no categories' option.
532+
* Default 'No categories'.
537533
* @type string $style The style used to display the categories list. If 'list', categories
538534
* will be output as an unordered list. If left empty or another value,
539535
* categories will be output separated by `<br>` tags. Default 'list'.
540-
* @type string $separator Separator between links. Default '<br />'.
536+
* @type string $taxonomy Taxonomy name. Default 'category'.
537+
* @type string $title_li Text to use for the list title `<li>` element. Pass an empty string
538+
* to disable. Default 'Categories'.
539+
* @type bool|int $use_desc_for_title Whether to use the category description as the title attribute.
540+
* Default 1.
541541
* }
542542
* @return false|string HTML content only if 'echo' argument is 0.
543543
*/

0 commit comments

Comments
 (0)