diff --git a/wp-includes/custom-navigation.php b/wp-includes/custom-navigation.php index a12b744f06..2fa8db24a1 100644 --- a/wp-includes/custom-navigation.php +++ b/wp-includes/custom-navigation.php @@ -227,11 +227,10 @@ function output_menu_item($menu_item, $context, $args = array() ) { break; case 'default': + $templatedir = get_bloginfo('url'); ?>
- - title; ?> <?php esc_attr_e('Add to Custom Menu'); ?>
post_parent == 0) { - // Custom Menu + if ( $post->post_parent == 0 ) { + $post = setup_menu_item($post, 'page', $intCounter); if ( $type == 'menu' ) { - $post = setup_menu_item($post, 'page', $intCounter); ?> -
  • -
    -
    post_title); - $post_url = get_permalink($post->ID); - $post_id = $post->ID; - $post_parent_id = $post->post_parent; - - $description = htmlentities(get_post_meta($post_id, 'page-description', true)); - - ?> - - - post_title; ?> Add to Custom Menu
    -
    - ID; ?> - - ID; + $intCounter++; + $intCounter = wp_custom_navigation_default_sub_items($post->ID, $intCounter, $parentli, 'pages', 'default'); ?> -
  • @@ -448,22 +416,10 @@ function wp_custom_nav_get_categories($counter, $type) { // Sidebar Menu ?>
  • -
    -
    cat_name); - $post_url = get_category_link($cat_item->cat_ID); - $post_id = $cat_item->cat_ID; - $post_parent_id = $cat_item->parent; - $description = htmlentities(strip_tags($cat_item->description)); - ?> - - cat_name); ?> =" title="="" src="" />
    -
    - cat_ID; ?> - - cat_ID; + $intCounter++; $intCounter = wp_custom_navigation_default_sub_items($cat_item->cat_ID, $intCounter, $parentli, 'categories', 'default'); ?> @@ -517,70 +473,32 @@ function wp_custom_navigation_default_sub_items($childof, $intCounter, $parentli cat_ID); - $title = htmlentities($sub_item->cat_name); - $parent_id = $sub_item->cat_ID; - $itemid = $sub_item->cat_ID; - $linktype = 'category'; - $appendtype = 'Category'; - $description = htmlentities(strip_tags($sub_item->description)); - } elseif ( $type == 'pages' ) { - //Page Menu Item - $link = get_permalink($sub_item->ID); - $title = htmlentities($sub_item->post_title); - $parent_id = $sub_item->ID; - $linktype = 'page'; - $itemid = $sub_item->ID; - $appendtype = 'Page'; - $description = htmlentities(get_post_meta($itemid, 'page-description', true)); - } else { - // Custom Menu Item - $title = ''; - $linktype = 'custom'; - $appendtype= 'Custom'; - } - - // Custom Menu if ( $output_type == 'menu' ) { ?>
  • -
    -
    - - - <?php esc_attr_e('Add to Custom Menu'); ?>
    -
    ID, $counter, $sub_item->ID, $type, 'default'); ?>