]> scripts.mit.edu Git - autoinstalls/wordpress.git/blobdiff - wp-admin/includes/class-wp-list-table.php
WordPress 3.4.2-scripts
[autoinstalls/wordpress.git] / wp-admin / includes / class-wp-list-table.php
index 446174d4dea6409f8a2ef7381caa485b3f05732a..6de7abf538c1c428671d40401bd3df6e0188a429 100644 (file)
@@ -212,7 +212,7 @@ class WP_List_Table {
 ?>
 <p class="search-box">
        <label class="screen-reader-text" for="<?php echo $input_id ?>"><?php echo $text; ?>:</label>
-       <input type="text" id="<?php echo $input_id ?>" name="s" value="<?php _admin_search_query(); ?>" />
+       <input type="search" id="<?php echo $input_id ?>" name="s" value="<?php _admin_search_query(); ?>" />
        <?php submit_button( $text, 'button', false, false, array('id' => 'search-submit') ); ?>
 </p>
 <?php
@@ -386,7 +386,8 @@ class WP_List_Table {
                        printf( "<option %s value='%s'>%s</option>\n",
                                selected( $m, $year . $month, false ),
                                esc_attr( $arc_row->year . $month ),
-                               $wp_locale->get_month( $month ) . " $year"
+                               /* translators: 1: month name, 2: 4-digit year */
+                               sprintf( __( '%1$s %2$d' ), $wp_locale->get_month( $month ), $year )
                        );
                }
 ?>
@@ -483,7 +484,7 @@ class WP_List_Table {
                if ( empty( $this->_pagination_args ) )
                        return;
 
-               extract( $this->_pagination_args );
+               extract( $this->_pagination_args, EXTR_SKIP );
 
                $output = '<span class="displaying-num">' . sprintf( _n( '1 item', '%s items', $total_items ), number_format_i18n( $total_items ) ) . '</span>';
 
@@ -518,9 +519,8 @@ class WP_List_Table {
                if ( 'bottom' == $which )
                        $html_current_page = $current;
                else
-                       $html_current_page = sprintf( "<input class='current-page' title='%s' type='text' name='%s' value='%s' size='%d' />",
+                       $html_current_page = sprintf( "<input class='current-page' title='%s' type='text' name='paged' value='%s' size='%d' />",
                                esc_attr__( 'Current page' ),
-                               esc_attr( 'paged' ),
                                $current,
                                strlen( $total_pages )
                        );
@@ -542,7 +542,10 @@ class WP_List_Table {
                        '&raquo;'
                );
 
-               $output .= "\n<span class='pagination-links'>" . join( "\n", $page_links ) . '</span>';
+               $pagination_links_class = 'pagination-links';
+               if ( ! empty( $infinite_scroll ) )
+                       $pagination_links_class = ' hide-if-js';
+               $output .= "\n<span class='$pagination_links_class'>" . join( "\n", $page_links ) . '</span>';
 
                if ( $total_pages )
                        $page_class = $total_pages < 2 ? ' one-page' : '';
@@ -871,7 +874,7 @@ class WP_List_Table {
                $this->prepare_items();
 
                extract( $this->_args );
-               extract( $this->_pagination_args );
+               extract( $this->_pagination_args, EXTR_SKIP );
 
                ob_start();
                if ( ! empty( $_REQUEST['no_placeholder'] ) )
@@ -913,4 +916,3 @@ class WP_List_Table {
                printf( "<script type='text/javascript'>list_args = %s;</script>\n", json_encode( $args ) );
        }
 }
-?>