Make WordPress Core

Changeset 19943


Ignore:
Timestamp:
02/17/2012 11:19:52 PM (15 years ago)
Author:
nacin
Message:

Only show 'Show on screen' once in screen options. fixes #17431.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-admin/includes/screen.php

    r19942 r19943  
    794794                <div id="screen-options-wrap" class="hidden">
    795795                <form id="adv-settings" action="" method="post">
     796                <?php if ( isset( $wp_meta_boxes[ $this->id ] ) || $this->get_option( 'per_page' ) || ( $columns && empty( $columns['_title'] ) ) ) : ?>
     797                        <h5><?php _e( 'Show on screen' ); ?></h5>
    796798                <?php
     799                endif;
     800
    797801                if ( isset( $wp_meta_boxes[ $this->id ] ) ) : ?>
    798                         <h5><?php _ex('Show on screen', 'Metaboxes') ?></h5>
    799802                        <div class="metabox-prefs">
    800803                                <?php
     
    818821                        </div>
    819822                        <?php endif;
    820                         if ( ! empty( $columns ) ) : ?>
    821                         <h5><?php echo ( isset( $columns['_title'] ) ? $columns['_title'] : _x('Show on screen', 'Columns') ) ?></h5>
     823                        if ( $columns ) :
     824                                if ( ! empty( $columns['_title'] ) ) : ?>
     825                        <h5><?php echo $columns['_title']; ?></h5>
     826                        <?php endif; ?>
    822827                        <div class="metabox-prefs">
    823828                                <?php
     
    934939
    935940                ?>
    936                 <h5><?php _ex('Show on screen', 'Screen Options') ?></h5>
    937941                <div class='screen-options'>
    938942                        <?php if ( !empty($per_page_label) ): ?>
Note: See TracChangeset for help on using the changeset viewer.