Make WordPress Core


Ignore:
Timestamp:
05/28/2010 11:04:00 PM (15 years ago)
Author:
nacin
Message:

Sanity check menu item parents and fix HTML issues. props filosofo, fixes #13600.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-admin/nav-menus.php

    r15010 r15049  
    563563                    <div id="post-body">
    564564                        <div id="post-body-content">
    565                             <?php if ( is_nav_menu( $nav_menu_selected_id ) ) : ?>
    566                                 <ul class="menu" id="menu-to-edit">
    567                                 <?php
     565                            <?php
     566                            if ( is_nav_menu( $nav_menu_selected_id ) ) :
    568567                                $edit_markup = wp_get_nav_menu_to_edit( $nav_menu_selected_id  );
    569                                 if ( ! is_wp_error( $edit_markup ) ) {
     568                                if ( ! is_wp_error( $edit_markup ) ) :
    570569                                    echo $edit_markup;
    571                                 }
    572                                 ?>
    573                                 </ul>
    574                             <?php elseif ( empty($nav_menu_selected_id) ):
     570                                endif;
     571                            elseif ( empty( $nav_menu_selected_id ) ) :
    575572                                echo '<div class="post-body-plain">';
    576573                                echo '<p>' . __('To create a custom menu, give it a name above and click Create Menu. Then choose items like pages, categories or custom links from the left column to add to this menu.') . '</p>';
     
    578575                                echo '<p>' . __('When you have finished building your custom menu, make sure you click the Save Menu button.') . '</p>';
    579576                                echo '</div>';
    580                             endif; ?>
     577                            endif;
     578                            ?>
    581579                        </div><!-- /#post-body-content -->
    582580                    </div><!-- /#post-body -->
Note: See TracChangeset for help on using the changeset viewer.