WordPress.org

Make WordPress Core

Ticket #19756: 19756.3.fixed.patch

File 19756.3.fixed.patch, 2.6 KB (added by roscius, 3 years ago)
  • wp-admin/includes/template.php

     
    1313// 
    1414 
    1515/** 
    16  * {@internal Missing Short Description}} 
     16 * Walker sub-class to output an unordered list of category checkbox form elements. 
     17 *  
     18 * @see Walker 
     19 * @see wp_category_checklist() 
    1720 * 
    1821 * @since 2.5.1 
    1922 */ 
     
    5154} 
    5255 
    5356/** 
    54  * {@internal Missing Short Description}} 
     57 * Outputs an unordered list of checkbox elements labeled with catagory names. 
    5558 * 
    5659 * @since 2.5.1 
    5760 * 
    58  * @param unknown_type $post_id 
    59  * @param unknown_type $descendants_and_self 
    60  * @param unknown_type $selected_cats 
    61  * @param unknown_type $popular_cats 
     61 * @param int $post_id Optional. If provided and $selected_cats is false, categories attached to post will be checked in list. 
     62 * @param int $descendants_and_self Optional.  Categories will be this term id along with its descendants. 
     63 * @param boolean|array $selected_cats Optional.  These categories in the list will be checked. 
     64 * @param boolean|array $popular_cats Optional.  These categories in the list will receive the class 'popular-category' 
     65 * @param object $walker Optional.  Walker object used in display of list. 
     66 * @param boolean $checked_ontop Optional.  Display the checked items in the list first. 
     67 * 
     68 * @see Walker 
    6269 */ 
    6370function wp_category_checklist( $post_id = 0, $descendants_and_self = 0, $selected_cats = false, $popular_cats = false, $walker = null, $checked_ontop = true ) { 
    6471        wp_terms_checklist($post_id, 
     
    141148} 
    142149 
    143150/** 
    144  * {@internal Missing Short Description}} 
     151 * Get an array of the most popular term ids from a taxonomy and optionally output an 
     152 * unordered list of checkbox elements for the terms.  The terms that are related to the 
     153 * current $post_id will be checked in the list. 
    145154 * 
    146155 * @since 2.5.0 
     156 *  
     157 * @uses $post_id 
    147158 * 
    148  * @param unknown_type $taxonomy 
    149  * @param unknown_type $default 
    150  * @param unknown_type $number 
    151  * @param unknown_type $echo 
    152  * @return unknown 
     159 * @param string|array $taxonomies The taxonomies to retrieve terms from. 
     160 * @param string $depreciated Optional.  Unused. 
     161 * @param int $number Optional. The number of terms to return.  Default is 10. 
     162 * @param boolean $echo Optional.  Whether to echo as well as return the result.  Default is true. 
     163 * @return array An array of the term ids. 
    153164 */ 
    154 function wp_popular_terms_checklist( $taxonomy, $default = 0, $number = 10, $echo = true ) { 
     165function wp_popular_terms_checklist( $taxonomy, $default = null, $number = 10, $echo = true ) { 
    155166        global $post_ID; 
    156167 
    157168        if ( $post_ID )