Changeset 5622
- Timestamp:
- 06/01/2007 02:24:07 AM (17 years ago)
- Location:
- trunk
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-admin/includes/template.php
r5612 r5622 101 101 } 102 102 103 $cats = get_categories(" child_of=$parent&hide_empty=0&fields=ids");103 $cats = get_categories("parent=$parent&hide_empty=0&fields=ids"); 104 104 105 105 $result = array (); -
trunk/wp-includes/taxonomy.php
r5616 r5622 481 481 $args = wp_parse_args( $args, $defaults ); 482 482 $args['number'] = (int) $args['number']; 483 if ( ! $single_taxonomy ) { 483 if ( !$single_taxonomy || !is_taxonomy_hierarchical($taxonomies[0]) || 484 '' != $args['parent'] ) { 484 485 $args['child_of'] = 0; 485 486 $args['hierarchical'] = false; 486 } else if ( !is_taxonomy_hierarchical($taxonomies[0]) ) { 487 $args['child_of'] = 0; 488 $args['hierarchical'] = false; 489 } 487 } 488 490 489 if ( 'all' == $args['get'] ) { 491 490 $args['child_of'] = 0; … … 498 497 $hierarchy = _get_term_hierarchy($taxonomies[0]); 499 498 if ( !isset($hierarchy[$child_of]) ) 499 return array(); 500 } 501 502 if ( $parent ) { 503 $hierarchy = _get_term_hierarchy($taxonomies[0]); 504 if ( !isset($hierarchy[$parent]) ) 500 505 return array(); 501 506 } … … 556 561 } 557 562 558 if ( !empty($parent)) {563 if ( '' != $parent ) { 559 564 $parent = (int) $parent; 560 565 $where = " AND tt.parent = '$parent'";
Note: See TracChangeset
for help on using the changeset viewer.