Changeset 13097
- Timestamp:
- 02/13/2010 07:42:02 AM (15 years ago)
- Location:
- trunk/wp-admin/includes
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-admin/includes/deprecated.php
r12871 r13097 55 55 } 56 56 57 /** 58 * {@internal Missing Short Description}} 59 * 60 * @since unknown 61 * @deprecated unknown 62 * @deprecated Use wp_category_checklist() 63 * @see wp_category_checklist() 64 * 65 * @param unknown_type $default 66 * @param unknown_type $parent 67 * @param unknown_type $popular_ids 68 */ 69 function dropdown_categories( $default = 0, $parent = 0, $popular_ids = array() ) { 70 _deprecated_function( __FUNCTION__, '0.0', 'wp_category_checklist()' ); 71 global $post_ID; 72 wp_category_checklist( $post_ID ); 73 } 74 75 /** 76 * {@internal Missing Short Description}} 77 * 78 * @since unknown 79 * @deprecated unknown 80 * @deprecated Use wp_link_category_checklist() 81 * @see wp_link_category_checklist() 82 * 83 * @param unknown_type $default 84 */ 85 function dropdown_link_categories( $default = 0 ) { 86 _deprecated_function( __FUNCTION__, '0.0', 'wp_link_category_checklist()' ); 87 global $link_id; 88 wp_link_category_checklist( $link_id ); 89 } 90 91 /** 92 * {@internal Missing Short Description}} 93 * 94 * @since unknown 95 * @deprecated 3.0.0 96 * @deprecated Use wp_dropdown_categories() 97 * @see wp_dropdown_categories() 98 * 99 * @param unknown_type $currentcat 100 * @param unknown_type $currentparent 101 * @param unknown_type $parent 102 * @param unknown_type $level 103 * @param unknown_type $categories 104 * @return unknown 105 */ 106 function wp_dropdown_cats( $currentcat = 0, $currentparent = 0, $parent = 0, $level = 0, $categories = 0 ) { 107 _deprecated_function( __FUNCTION__, '3.0', 'wp_dropdown_categories()' ); 108 if (!$categories ) 109 $categories = get_categories( array('hide_empty' => 0) ); 110 111 if ( $categories ) { 112 foreach ( $categories as $category ) { 113 if ( $currentcat != $category->term_id && $parent == $category->parent) { 114 $pad = str_repeat( '– ', $level ); 115 $category->name = esc_html( $category->name ); 116 echo "\n\t<option value='$category->term_id'"; 117 if ( $currentparent == $category->term_id ) 118 echo " selected='selected'"; 119 echo ">$pad$category->name</option>"; 120 wp_dropdown_cats( $currentcat, $currentparent, $category->term_id, $level +1, $categories ); 121 } 122 } 123 } else { 124 return false; 125 } 126 } 127 57 128 ?> -
trunk/wp-admin/includes/template.php
r13086 r13097 235 235 * 236 236 * @since unknown 237 * @deprecated Use {@link wp_link_category_checklist()}238 * @see wp_link_category_checklist()239 *240 * @param unknown_type $default241 * @param unknown_type $parent242 * @param unknown_type $popular_ids243 */244 function dropdown_categories( $default = 0, $parent = 0, $popular_ids = array() ) {245 global $post_ID;246 wp_category_checklist($post_ID);247 }248 249 /**250 * {@internal Missing Short Description}}251 *252 * @since unknown253 237 */ 254 238 class Walker_Category_Checklist extends Walker { … … 419 403 } 420 404 return $popular_ids; 421 }422 423 /**424 * {@internal Missing Short Description}}425 *426 * @since unknown427 * @deprecated Use {@link wp_link_category_checklist()}428 * @see wp_link_category_checklist()429 *430 * @param unknown_type $default431 */432 function dropdown_link_categories( $default = 0 ) {433 global $link_id;434 435 wp_link_category_checklist($link_id);436 405 } 437 406 … … 2348 2317 * @since unknown 2349 2318 * 2350 * @param unknown_type $currentcat2351 * @param unknown_type $currentparent2352 * @param unknown_type $parent2353 * @param unknown_type $level2354 * @param unknown_type $categories2355 * @return unknown2356 */2357 function wp_dropdown_cats( $currentcat = 0, $currentparent = 0, $parent = 0, $level = 0, $categories = 0 ) {2358 if (!$categories )2359 $categories = get_categories( array('hide_empty' => 0) );2360 2361 if ( $categories ) {2362 foreach ( $categories as $category ) {2363 if ( $currentcat != $category->term_id && $parent == $category->parent) {2364 $pad = str_repeat( '– ', $level );2365 $category->name = esc_html( $category->name );2366 echo "\n\t<option value='$category->term_id'";2367 if ( $currentparent == $category->term_id )2368 echo " selected='selected'";2369 echo ">$pad$category->name</option>";2370 wp_dropdown_cats( $currentcat, $currentparent, $category->term_id, $level +1, $categories );2371 }2372 }2373 } else {2374 return false;2375 }2376 }2377 2378 /**2379 * {@internal Missing Short Description}}2380 *2381 * @since unknown2382 *2383 2319 * @param unknown_type $meta 2384 2320 */
Note: See TracChangeset
for help on using the changeset viewer.