]> scripts.mit.edu Git - autoinstalls/wordpress.git/blobdiff - wp-admin/includes/class-wp-plugins-list-table.php
Wordpress 3.2
[autoinstalls/wordpress.git] / wp-admin / includes / class-wp-plugins-list-table.php
index b5ad6d48b6eefbd4095b9e837f0a090687b97e72..99ce21278e8587500b3c4c19bf97e83ef3687968 100644 (file)
@@ -9,7 +9,7 @@
  */
 class WP_Plugins_List_Table extends WP_List_Table {
 
-       function WP_Plugins_List_Table() {
+       function __construct() {
                global $status, $page;
 
                $default_status = get_user_option( 'plugins_last_view' );
@@ -21,13 +21,17 @@ class WP_Plugins_List_Table extends WP_List_Table {
                if ( $status != $default_status && 'search' != $status )
                        update_user_meta( get_current_user_id(), 'plugins_last_view', $status );
 
+
+               if ( isset($_REQUEST['s']) )
+                       $_SERVER['REQUEST_URI'] = add_query_arg('s', stripslashes($_REQUEST['s']) );
+
                $page = $this->get_pagenum();
 
-               parent::WP_List_Table( array(
+               parent::__construct( array(
                        'plural' => 'plugins',
                ) );
        }
-       
+
        function get_table_classes() {
                return array( 'widefat', $this->_args['plural'] );
        }
@@ -132,7 +136,7 @@ class WP_Plugins_List_Table extends WP_List_Table {
                        uasort( $this->items, array( &$this, '_order_callback' ) );
                }
 
-               $plugins_per_page = $this->get_items_per_page( str_replace( '-', '_', $screen->id . '_per_page' ) );
+               $plugins_per_page = $this->get_items_per_page( str_replace( '-', '_', $screen->id . '_per_page' ), 999 );
 
                $start = ( $page - 1 ) * $plugins_per_page;
 
@@ -287,9 +291,9 @@ class WP_Plugins_List_Table extends WP_List_Table {
                if ( 'recently_activated' == $status )
                        submit_button( __( 'Clear List' ), 'secondary', 'clear-recent-list', false );
                elseif ( 'top' == $which && 'mustuse' == $status )
-                       echo '<p>' . __( 'Files in the <code>/wp-content/mu-plugins</code> directory are executed automatically.' ) . '</p>';
+                       echo '<p>' . sprintf( __( 'Files in the <code>%s</code> directory are executed automatically.' ), str_replace( ABSPATH, '/', WPMU_PLUGIN_DIR ) ) . '</p>';
                elseif ( 'top' == $which && 'dropins' == $status )
-                       echo '<p>' . __( 'Drop-ins are advanced plugins in the <code>/wp-content</code> directory that replace WordPress functionality when present.' ) . '</p>';
+                       echo '<p>' . sprintf( __( 'Drop-ins are advanced plugins in the <code>%s</code> directory that replace WordPress functionality when present.' ), str_replace( ABSPATH, '', WP_CONTENT_DIR ) ) . '</p>';
 
                echo '</div>';
        }