WordPress.org

Make WordPress Core

Ticket #47896: 47896.diff

File 47896.diff, 1.3 KB (added by audrasjb, 10 months ago)

Document include argument in wp_list_categories()

  • src/wp-includes/category-template.php

    diff --git a/src/wp-includes/category-template.php b/src/wp-includes/category-template.php
    index e3729df..b23a476 100644
    a b function wp_dropdown_categories( $args = '' ) { 
    494494 *                                               the list. Default false (title will always be shown).
    495495 *     @type bool         $hierarchical          Whether to include terms that have non-empty descendants.
    496496 *                                               See get_terms(). Default true.
     497 *     @type array|string $include               Array or comma/space-separated string of term ids to include.
     498 *                                               See get_terms(). Default empty string.
    497499 *     @type string       $order                 Which direction to order categories. Accepts 'ASC' or 'DESC'.
    498500 *                                               Default 'ASC'.
    499501 *     @type string       $orderby               The column to use for ordering categories. Default 'name'.
    function wp_list_categories( $args = '' ) { 
    527529                'hide_empty'          => 1,
    528530                'hide_title_if_empty' => false,
    529531                'hierarchical'        => true,
     532                'include'             => '',
    530533                'order'               => 'ASC',
    531534                'orderby'             => 'name',
    532535                'separator'           => '<br />',