Block editing of sites in a network other than the current one. Props wpmuguru. see #14185 for 3.1

git-svn-id: https://develop.svn.wordpress.org/trunk@15385 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Ryan Boren 2010-07-12 15:01:25 +00:00
parent 8d9d4817a3
commit b155b1e304

View File

@ -107,6 +107,9 @@ switch ( $action ) {
$blog_prefix = $wpdb->get_blog_prefix( $id );
$options = $wpdb->get_results( "SELECT * FROM {$blog_prefix}options WHERE option_name NOT LIKE '\_%' AND option_name NOT LIKE '%user_roles'" );
$details = get_blog_details( $id );
if ( $details->site_id != $wpdb->siteid )
wp_die( __( 'You do not have permission to access this page.' ) );
$editblog_roles = get_blog_option( $id, "{$blog_prefix}user_roles" );
$is_main_site = is_main_site( $id );
?>