Changeset 15528
- Timestamp:
- 08/25/2010 12:51:44 AM (14 years ago)
- Location:
- trunk/wp-admin
- Files:
-
- 16 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-admin/admin-ajax.php
r15519 r15528 52 52 switch ( $action = $_GET['action'] ) : 53 53 case 'fetch-list' : 54 require_once( './includes/default-list-tables.php' );54 require_once( ABSPATH . '/wp-admin/includes/default-list-tables.php' ); 55 55 56 56 $class = $_GET['list_args']['class']; 57 57 58 58 if ( class_exists( $class ) ) { 59 global $current_screen;60 59 $current_screen = (object) $_GET['list_args']['screen']; 61 60 $wp_list_table = new $class; … … 558 557 set_current_screen($_POST['screen']); 559 558 560 require_once( './includes/default-list-tables.php' ); 561 $wp_list_table = new WP_Terms_Table(); 559 $wp_list_table = get_list_table('terms'); 562 560 563 561 $level = 0; … … 626 624 die('-1'); 627 625 628 require_once( './includes/default-list-tables.php' ); 629 $wp_list_table = new WP_Comments_Table(); 626 $wp_list_table = get_list_table('comments'); 630 627 $wp_list_table->prepare_items(); 631 628 … … 655 652 die('-1'); 656 653 657 require_once( './includes/default-list-tables.php' ); 658 $wp_list_table = new WP_Comments_Table(); 654 $wp_list_table = get_list_table('comments'); 659 655 $wp_list_table->prepare_items(); 660 656 … … 680 676 check_ajax_referer( $action, '_ajax_nonce-replyto-comment' ); 681 677 682 require_once( './includes/default-list-tables.php' ); 683 $wp_list_table = new WP_Comments_Table(); 678 $wp_list_table = get_list_table('comments'); 684 679 685 680 $comment_post_ID = (int) $_POST['comment_post_ID']; … … 762 757 $comments_listing = isset($_POST['comments_listing']) ? $_POST['comments_listing'] : ''; 763 758 764 require_once( './includes/default-list-tables.php' ); 765 $wp_list_table = new WP_Comments_Table(); 759 $wp_list_table = get_list_table('comments'); 766 760 767 761 ob_start(); … … 911 905 $user_object = new WP_User( $user_id ); 912 906 913 require_once( './includes/default-list-tables.php' ); 914 $wp_list_table = new WP_Users_Table(); 907 $wp_list_table = get_list_table('users'); 915 908 916 909 $x = new WP_Ajax_Response( array( … … 1204 1197 edit_post(); 1205 1198 1206 require_once( './includes/default-list-tables.php' ); 1207 $wp_list_table = new WP_Posts_Table(); 1199 $wp_list_table = get_list_table('posts'); 1208 1200 1209 1201 $mode = $_POST['post_view']; … … 1215 1207 check_ajax_referer( 'taxinlineeditnonce', '_inline_edit' ); 1216 1208 1217 require_once( './includes/default-list-tables.php' ); 1218 $wp_list_table = new WP_Terms_Table(); 1209 $wp_list_table = get_list_table('terms'); 1219 1210 1220 1211 $wp_list_table->check_permissions('edit'); -
trunk/wp-admin/edit-comments.php
r15519 r15528 10 10 require_once('./admin.php'); 11 11 12 require_once( './includes/default-list-tables.php' ); 13 14 $wp_list_table = new WP_Comments_Table; 12 $wp_list_table = get_list_table('comments'); 15 13 $wp_list_table->check_permissions(); 16 14 -
trunk/wp-admin/edit-tags.php
r15519 r15528 10 10 require_once('./admin.php'); 11 11 12 require_once( './includes/default-list-tables.php' ); 13 14 $wp_list_table = new WP_Terms_Table; 12 $wp_list_table = get_list_table('terms'); 15 13 $wp_list_table->check_permissions(); 16 14 -
trunk/wp-admin/edit.php
r15523 r15528 10 10 require_once( './admin.php' ); 11 11 12 require_once( './includes/default-list-tables.php' ); 13 14 $wp_list_table = new WP_Posts_Table; 12 $wp_list_table = get_list_table('posts'); 15 13 $wp_list_table->check_permissions(); 16 14 -
trunk/wp-admin/includes/list-table.php
r15517 r15528 629 629 630 630 /** 631 * Handle an incoming ajax request ( called from admin-ajax.php ) 632 * 631 * Handle an incoming ajax request (called from admin-ajax.php) 632 * 633 * @since 3.1.0 633 634 * @access public 634 635 */ … … 666 667 } 667 668 } 669 670 /** 671 * Fetch an instance of a WP_List_Table class 672 * 673 * @since 3.1.0 674 * 675 * @param string $type The type of the list table 676 * @return object 677 */ 678 function get_list_table( $type ) { 679 require_once( ABSPATH . '/wp-admin/includes/default-list-tables.php' ); 680 681 $type = strtr( ucwords( strtr( $type, '-', ' ') ), ' ', '_' ); 682 683 $class = "WP_{$type}_Table"; 684 $class = apply_filters( "get_list_table_$type", $class ); 685 686 return new $class; 687 } 688 -
trunk/wp-admin/includes/meta-boxes.php
r15519 r15528 463 463 add_filter('manage_edit-comments_sortable_columns', create_function('', 'return array();'), 8); 464 464 465 require_once( './includes/default-list-tables.php' ); 466 $wp_list_table = new WP_Comments_Table; 465 $wp_list_table = get_list_table('comments'); 467 466 ?> 468 467 -
trunk/wp-admin/includes/template.php
r15519 r15528 294 294 } 295 295 296 require_once( './includes/default-list-tables.php' ); 297 $wp_list_table = new WP_Comments_Table( 'reply' ); 296 $wp_list_table = get_list_table('comments'); 298 297 299 298 $columns = $wp_list_table->get_column_headers(); -
trunk/wp-admin/link-manager.php
r15519 r15528 10 10 require_once ('admin.php'); 11 11 12 require_once( './includes/default-list-tables.php' ); 13 14 $wp_list_table = new WP_Links_Table; 12 $wp_list_table = get_list_table('links'); 15 13 $wp_list_table->check_permissions(); 16 14 -
trunk/wp-admin/network/sites.php
r15519 r15528 13 13 wp_die( __( 'Multisite support is not enabled.' ) ); 14 14 15 require_once( '../includes/default-list-tables.php' ); 16 17 $wp_list_table = new WP_Sites_Table; 15 $wp_list_table = get_list_table('sites'); 18 16 $wp_list_table->check_permissions(); 19 17 -
trunk/wp-admin/network/users.php
r15519 r15528 10 10 require_once( './admin.php' ); 11 11 12 require_once( '../includes/default-list-tables.php' ); 13 14 $wp_list_table = new WP_MS_Users_Table; 12 $wp_list_table = get_list_table('ms-users'); 15 13 $wp_list_table->check_permissions(); 16 14 $wp_list_table->prepare_items(); -
trunk/wp-admin/plugin-install.php
r15519 r15528 10 10 require_once('./admin.php'); 11 11 12 require_once( './includes/default-list-tables.php' ); 13 14 $wp_list_table = new WP_Plugin_Install_Table; 12 $wp_list_table = get_list_table('plugin-install'); 15 13 $wp_list_table->check_permissions(); 16 14 $wp_list_table->prepare_items(); -
trunk/wp-admin/plugins.php
r15527 r15528 10 10 require_once('./admin.php'); 11 11 12 require_once( ABSPATH . 'wp-admin/includes/default-list-tables.php' ); 13 14 $wp_list_table = new WP_Plugins_Table; 12 $wp_list_table = get_list_table('plugins'); 15 13 $wp_list_table->check_permissions(); 16 14 -
trunk/wp-admin/theme-install.php
r15519 r15528 10 10 require_once('./admin.php'); 11 11 12 require_once( './includes/default-list-tables.php' ); 13 14 $wp_list_table = new WP_Theme_Install_Table; 12 $wp_list_table = get_list_table('theme-install'); 15 13 $wp_list_table->check_permissions(); 16 14 $wp_list_table->prepare_items(); -
trunk/wp-admin/themes.php
r15519 r15528 10 10 require_once('./admin.php'); 11 11 12 require_once( './includes/default-list-tables.php' ); 13 14 $wp_list_table = new WP_Themes_Table; 12 $wp_list_table = get_list_table('themes'); 15 13 $wp_list_table->check_permissions(); 16 14 -
trunk/wp-admin/upload.php
r15519 r15528 10 10 require_once( './admin.php' ); 11 11 12 require_once( './includes/default-list-tables.php' ); 13 14 $wp_list_table = new WP_Media_Table; 12 $wp_list_table = get_list_table('media'); 15 13 $wp_list_table->check_permissions(); 16 14 -
trunk/wp-admin/users.php
r15519 r15528 13 13 require_once( ABSPATH . WPINC . '/registration.php'); 14 14 15 require_once( './includes/default-list-tables.php' ); 16 17 $wp_list_table = new WP_Users_Table; 15 $wp_list_table = get_list_table('users'); 18 16 $wp_list_table->check_permissions(); 19 17
Note: See TracChangeset
for help on using the changeset viewer.