Changeset 6835
- Timestamp:
- 02/14/2008 12:54:52 AM (17 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-includes/classes.php
r6726 r6835 418 418 $parent_field = $this->db_fields['parent']; 419 419 420 if ($depth > 0) {421 //start the child delimiter422 $cb_args = array_merge( array($output, $depth), $args);423 $output = call_user_func_array(array(&$this, 'start_lvl'), $cb_args);424 }425 426 420 //display this element 427 421 $cb_args = array_merge( array($output, $element, $depth), $args); … … 433 427 if ( $child->$parent_field == $element->$id_field ) { 434 428 429 if ( !isset($newlevel) ) { 430 $newlevel = true; 431 //start the child delimiter 432 $cb_args = array_merge( array($output, $depth), $args); 433 $output = call_user_func_array(array(&$this, 'start_lvl'), $cb_args); 434 } 435 435 436 array_splice( $children_elements, $i, 1 ); 436 437 $output = $this->display_element( $child, $children_elements, $max_depth, $depth + 1, $args, $output ); … … 439 440 } 440 441 442 if ( isset($newlevel) && $newlevel ){ 443 //end the child delimiter 444 $cb_args = array_merge( array($output, $depth), $args); 445 $output = call_user_func_array(array(&$this, 'end_lvl'), $cb_args); 446 } 447 441 448 //end this element 442 449 $cb_args = array_merge( array($output, $element, $depth), $args); 443 450 $output = call_user_func_array(array(&$this, 'end_el'), $cb_args); 444 445 if ($depth > 0) {446 //end the child delimiter447 $cb_args = array_merge( array($output, $depth), $args);448 $output = call_user_func_array(array(&$this, 'end_lvl'), $cb_args);449 }450 451 451 452 return $output;
Note: See TracChangeset
for help on using the changeset viewer.