Changeset 34912 for trunk/src/wp-admin/includes/ms.php
- Timestamp:
- 10/07/2015 05:11:01 PM (9 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-admin/includes/ms.php
r34778 r34912 17 17 */ 18 18 function check_upload_size( $file ) { 19 if ( get_ network_option( 'upload_space_check_disabled' ) )19 if ( get_site_option( 'upload_space_check_disabled' ) ) 20 20 return $file; 21 21 … … 31 31 if ( $space_left < $file_size ) 32 32 $file['error'] = sprintf( __( 'Not enough space to upload. %1$s KB needed.' ), number_format( ($file_size - $space_left) /1024 ) ); 33 if ( $file_size > ( 1024 * get_ network_option( 'fileupload_maxk', 1500 ) ) )34 $file['error'] = sprintf(__('This file is too big. Files must be less than %1$s KB in size.'), get_ network_option( 'fileupload_maxk', 1500 ) );33 if ( $file_size > ( 1024 * get_site_option( 'fileupload_maxk', 1500 ) ) ) 34 $file['error'] = sprintf(__('This file is too big. Files must be less than %1$s KB in size.'), get_site_option( 'fileupload_maxk', 1500 ) ); 35 35 if ( upload_is_user_over_quota( false ) ) { 36 36 $file['error'] = __( 'You have used your space quota. Please delete files before uploading.' ); … … 99 99 100 100 // If ms_files_rewriting is enabled and upload_path is empty, wp_upload_dir is not reliable. 101 if ( $drop && get_ network_option( 'ms_files_rewriting' ) && empty( $upload_path ) ) {101 if ( $drop && get_site_option( 'ms_files_rewriting' ) && empty( $upload_path ) ) { 102 102 $drop = false; 103 103 } … … 307 307 $content = str_replace( '###ADMIN_URL###', esc_url( admin_url( 'options.php?adminhash='.$hash ) ), $content ); 308 308 $content = str_replace( '###EMAIL###', $value, $content ); 309 $content = str_replace( '###SITENAME###', get_ network_option( 'site_name' ), $content );309 $content = str_replace( '###SITENAME###', get_site_option( 'site_name' ), $content ); 310 310 $content = str_replace( '###SITEURL###', network_home_url(), $content ); 311 311 … … 386 386 $content = str_replace( '###ADMIN_URL###', esc_url( admin_url( 'profile.php?newuseremail='.$hash ) ), $content ); 387 387 $content = str_replace( '###EMAIL###', $_POST['email'], $content); 388 $content = str_replace( '###SITENAME###', get_ network_option( 'site_name' ), $content );388 $content = str_replace( '###SITENAME###', get_site_option( 'site_name' ), $content ); 389 389 $content = str_replace( '###SITEURL###', network_home_url(), $content ); 390 390 … … 414 414 */ 415 415 function upload_is_user_over_quota( $echo = true ) { 416 if ( get_ network_option( 'upload_space_check_disabled' ) )416 if ( get_site_option( 'upload_space_check_disabled' ) ) 417 417 return false; 418 418 … … 747 747 if ( !is_super_admin() ) 748 748 return false; 749 if ( get_ network_option( 'wpmu_upgrade_site' ) != $wp_db_version )749 if ( get_site_option( 'wpmu_upgrade_site' ) != $wp_db_version ) 750 750 echo "<div class='update-nag'>" . sprintf( __( 'Thank you for Updating! Please visit the <a href="%s">Upgrade Network</a> page to update all your sites.' ), esc_url( network_admin_url( 'upgrade.php' ) ) ) . "</div>"; 751 751 } … … 829 829 </td> 830 830 </tr> 831 <?php if ( in_array( get_ network_option( 'registration' ), array( 'all', 'blog' ) ) ) : ?>831 <?php if ( in_array( get_site_option( 'registration' ), array( 'all', 'blog' ) ) ) : ?> 832 832 <tr> 833 833 <th scope="row" colspan="2" class="th-full"> … … 871 871 872 872 // Directly fetch site_admins instead of using get_super_admins() 873 $super_admins = get_ network_option( 'site_admins', array( 'admin' ) );873 $super_admins = get_site_option( 'site_admins', array( 'admin' ) ); 874 874 875 875 $user = get_userdata( $user_id ); 876 876 if ( $user && ! in_array( $user->user_login, $super_admins ) ) { 877 877 $super_admins[] = $user->user_login; 878 update_ network_option( 'site_admins' , $super_admins );878 update_site_option( 'site_admins' , $super_admins ); 879 879 880 880 /** … … 918 918 919 919 // Directly fetch site_admins instead of using get_super_admins() 920 $super_admins = get_ network_option( 'site_admins', array( 'admin' ) );920 $super_admins = get_site_option( 'site_admins', array( 'admin' ) ); 921 921 922 922 $user = get_userdata( $user_id ); 923 if ( $user && 0 !== strcasecmp( $user->user_email, get_ network_option( 'admin_email' ) ) ) {923 if ( $user && 0 !== strcasecmp( $user->user_email, get_site_option( 'admin_email' ) ) ) { 924 924 if ( false !== ( $key = array_search( $user->user_login, $super_admins ) ) ) { 925 925 unset( $super_admins[$key] ); 926 update_ network_option( 'site_admins', $super_admins );926 update_site_option( 'site_admins', $super_admins ); 927 927 928 928 /**
Note: See TracChangeset
for help on using the changeset viewer.