Changeset 32531
- Timestamp:
- 05/21/2015 09:04:32 PM (9 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-includes/category-template.php
r32484 r32531 480 480 * 481 481 * @param string|array $args Optional. Override default arguments. 482 * @return false| null|string HTML content only if 'echo' argument is 0.482 * @return false|string HTML content only if 'echo' argument is 0. 483 483 */ 484 484 function wp_list_categories( $args = '' ) { … … 630 630 * 631 631 * @param array|string|null $args Optional. Override default arguments. 632 * @return null|false Generated tag cloud, only if no failures and 'array' is set for the 'format' argument. 632 * @return null|array Generated tag cloud, only if no failures and 'array' is set for the 'format' argument. 633 * Otherwise, this function outputs the tag cloud. 633 634 */ 634 635 function wp_tag_cloud( $args = '' ) { … … 651 652 $link = get_term_link( intval($tag->term_id), $tag->taxonomy ); 652 653 if ( is_wp_error( $link ) ) 653 return false;654 return; 654 655 655 656 $tags[ $key ]->link = $link; … … 678 679 * Default topic count scaling for tag links 679 680 * 680 * @param int eger$count number of posts with that tag681 * @return int egerscaled count681 * @param int $count number of posts with that tag 682 * @return int scaled count 682 683 */ 683 684 function default_topic_count_scale( $count ) { … … 869 870 * @since 3.1.0 870 871 * @access private 872 * @return int 871 873 */ 872 874 function _wp_object_name_sort_cb( $a, $b ) { … … 879 881 * @since 3.1.0 880 882 * @access private 883 * @return bool 881 884 */ 882 885 function _wp_object_count_sort_cb( $a, $b ) { … … 894 897 * @since 2.1.0 895 898 * @see Walker_Category::walk() for parameters and return description. 899 * @return string 896 900 */ 897 901 function walk_category_tree() { … … 903 907 $walker = $args[2]['walker']; 904 908 } 905 return call_user_func_array( array( &$walker, 'walk' ), $args );909 return call_user_func_array( array( $walker, 'walk' ), $args ); 906 910 } 907 911 … … 912 916 * @since 2.1.0 913 917 * @see Walker_CategoryDropdown::walk() for parameters and return description. 918 * @return string 914 919 */ 915 920 function walk_category_dropdown_tree() { 916 921 $args = func_get_args(); 917 922 // the user's options are the third parameter 918 if ( empty( $args[2]['walker']) || !is_a($args[2]['walker'], 'Walker') )923 if ( empty( $args[2]['walker'] ) || ! ( $args[2]['walker'] instanceof Walker ) ) { 919 924 $walker = new Walker_CategoryDropdown; 920 else925 } else { 921 926 $walker = $args[2]['walker']; 922 923 return call_user_func_array( array( &$walker, 'walk' ), $args );927 } 928 return call_user_func_array( array( $walker, 'walk' ), $args ); 924 929 } 925 930 … … 1215 1220 * 1216 1221 * @param int $id Post ID. 1217 * @return array| boolArray of tag objects on success, false on failure.1222 * @return array|false|WP_Error Array of tag objects on success, false on failure. 1218 1223 */ 1219 1224 function get_the_tags( $id = 0 ) { … … 1240 1245 * @param string $after Optional. After tags. 1241 1246 * @param int $id Optional. Post ID. Defaults to the current post. 1242 * @return string| bool|WP_Error A list of tags on success, false if there are no terms, WP_Error on failure.1247 * @return string|false|WP_Error A list of tags on success, false if there are no terms, WP_Error on failure. 1243 1248 */ 1244 1249 function get_the_tag_list( $before = '', $sep = '', $after = '', $id = 0 ) { … … 1313 1318 * @param int|object $post Post ID or object. 1314 1319 * @param string $taxonomy Taxonomy name. 1315 * @return array| bool|WP_Error Array of term objects on success, false if there are no terms1316 * or the post does not exist, WP_Error on failure.1320 * @return array|false|WP_Error Array of term objects on success, false if there are no terms 1321 * or the post does not exist, WP_Error on failure. 1317 1322 */ 1318 1323 function get_the_terms( $post, $taxonomy ) { … … 1353 1358 * @param string $sep Optional. Separate items using this. 1354 1359 * @param string $after Optional. After list. 1355 * @return string| bool|WP_Error A list of terms on success, false if there are no terms, WP_Error on failure.1360 * @return string|false|WP_Error A list of terms on success, false if there are no terms, WP_Error on failure. 1356 1361 */ 1357 1362 function get_the_term_list( $id, $taxonomy, $before = '', $sep = '', $after = '' ) {
Note: See TracChangeset
for help on using the changeset viewer.