Changeset 34912 for trunk/src/wp-admin/network/settings.php
- Timestamp:
- 10/07/2015 05:11:01 PM (9 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-admin/network/settings.php
r34778 r34912 77 77 continue; 78 78 $value = wp_unslash( $_POST[$option_name] ); 79 update_ network_option( $option_name, $value );79 update_site_option( $option_name, $value ); 80 80 } 81 81 … … 114 114 <th scope="row"><label for="admin_email"><?php _e( 'Network Admin Email' ) ?></label></th> 115 115 <td> 116 <input name="admin_email" type="email" id="admin_email" aria-describedby="admin-email-desc" class="regular-text" value="<?php echo esc_attr( get_ network_option( 'admin_email' ) ) ?>" />116 <input name="admin_email" type="email" id="admin_email" aria-describedby="admin-email-desc" class="regular-text" value="<?php echo esc_attr( get_site_option( 'admin_email' ) ) ?>" /> 117 117 <p class="description" id="admin-email-desc"> 118 118 <?php _e( 'This email address will receive notifications. Registration and support emails will also come from this address.' ); ?> … … 126 126 <th scope="row"><?php _e( 'Allow new registrations' ) ?></th> 127 127 <?php 128 if ( !get_ network_option( 'registration' ) )129 update_ network_option( 'registration', 'none' );130 $reg = get_ network_option( 'registration' );128 if ( !get_site_option( 'registration' ) ) 129 update_site_option( 'registration', 'none' ); 130 $reg = get_site_option( 'registration' ); 131 131 ?> 132 132 <td> … … 147 147 <th scope="row"><?php _e( 'Registration notification' ) ?></th> 148 148 <?php 149 if ( !get_ network_option( 'registrationnotification' ) )150 update_ network_option( 'registrationnotification', 'yes' );149 if ( !get_site_option( 'registrationnotification' ) ) 150 update_site_option( 'registrationnotification', 'yes' ); 151 151 ?> 152 152 <td> 153 <label><input name="registrationnotification" type="checkbox" id="registrationnotification" value="yes"<?php checked( get_ network_option( 'registrationnotification' ), 'yes' ) ?> /> <?php _e( 'Send the network admin an email notification every time someone registers a site or user account.' ) ?></label>153 <label><input name="registrationnotification" type="checkbox" id="registrationnotification" value="yes"<?php checked( get_site_option( 'registrationnotification' ), 'yes' ) ?> /> <?php _e( 'Send the network admin an email notification every time someone registers a site or user account.' ) ?></label> 154 154 </td> 155 155 </tr> … … 158 158 <th scope="row"><?php _e( 'Add New Users' ) ?></th> 159 159 <td> 160 <label><input name="add_new_users" type="checkbox" id="add_new_users" value="1"<?php checked( get_ network_option( 'add_new_users' ) ) ?> /> <?php _e( 'Allow site administrators to add new users to their site via the "Users → Add New" page.' ); ?></label>160 <label><input name="add_new_users" type="checkbox" id="add_new_users" value="1"<?php checked( get_site_option( 'add_new_users' ) ) ?> /> <?php _e( 'Allow site administrators to add new users to their site via the "Users → Add New" page.' ); ?></label> 161 161 </td> 162 162 </tr> … … 165 165 <th scope="row"><label for="illegal_names"><?php _e( 'Banned Names' ) ?></label></th> 166 166 <td> 167 <input name="illegal_names" type="text" id="illegal_names" aria-describedby="illegal-names-desc" class="large-text" value="<?php echo esc_attr( implode( " ", (array) get_ network_option( 'illegal_names' ) ) ); ?>" size="45" />167 <input name="illegal_names" type="text" id="illegal_names" aria-describedby="illegal-names-desc" class="large-text" value="<?php echo esc_attr( implode( " ", (array) get_site_option( 'illegal_names' ) ) ); ?>" size="45" /> 168 168 <p class="description" id="illegal-names-desc"> 169 169 <?php _e( 'Users are not allowed to register these sites. Separate names by spaces.' ) ?> … … 175 175 <th scope="row"><label for="limited_email_domains"><?php _e( 'Limited Email Registrations' ) ?></label></th> 176 176 <td> 177 <?php $limited_email_domains = get_ network_option( 'limited_email_domains' );177 <?php $limited_email_domains = get_site_option( 'limited_email_domains' ); 178 178 $limited_email_domains = str_replace( ' ', "\n", $limited_email_domains ); ?> 179 179 <textarea name="limited_email_domains" id="limited_email_domains" aria-describedby="limited-email-domains-desc" cols="45" rows="5"> … … 189 189 <td> 190 190 <textarea name="banned_email_domains" id="banned_email_domains" aria-describedby="banned-email-domains-desc" cols="45" rows="5"> 191 <?php echo esc_textarea( get_ network_option( 'banned_email_domains' ) == '' ? '' : implode( "\n", (array) get_network_option( 'banned_email_domains' ) ) ); ?></textarea>191 <?php echo esc_textarea( get_site_option( 'banned_email_domains' ) == '' ? '' : implode( "\n", (array) get_site_option( 'banned_email_domains' ) ) ); ?></textarea> 192 192 <p class="description" id="banned-email-domains-desc"> 193 193 <?php _e( 'If you want to ban domains from site registrations. One domain per line.' ) ?> … … 204 204 <td> 205 205 <textarea name="welcome_email" id="welcome_email" aria-describedby="welcome-email-desc" rows="5" cols="45" class="large-text"> 206 <?php echo esc_textarea( get_ network_option( 'welcome_email' ) ) ?></textarea>206 <?php echo esc_textarea( get_site_option( 'welcome_email' ) ) ?></textarea> 207 207 <p class="description" id="welcome-email-desc"> 208 208 <?php _e( 'The welcome email sent to new site owners.' ) ?> … … 214 214 <td> 215 215 <textarea name="welcome_user_email" id="welcome_user_email" aria-describedby="welcome-user-email-desc" rows="5" cols="45" class="large-text"> 216 <?php echo esc_textarea( get_ network_option( 'welcome_user_email' ) ) ?></textarea>216 <?php echo esc_textarea( get_site_option( 'welcome_user_email' ) ) ?></textarea> 217 217 <p class="description" id="welcome-user-email-desc"> 218 218 <?php _e( 'The welcome email sent to new users.' ) ?> … … 224 224 <td> 225 225 <textarea name="first_post" id="first_post" aria-describedby="first-post-desc" rows="5" cols="45" class="large-text"> 226 <?php echo esc_textarea( get_ network_option( 'first_post' ) ) ?></textarea>226 <?php echo esc_textarea( get_site_option( 'first_post' ) ) ?></textarea> 227 227 <p class="description" id="first-post-desc"> 228 228 <?php _e( 'The first post on a new site.' ) ?> … … 234 234 <td> 235 235 <textarea name="first_page" id="first_page" aria-describedby="first-page-desc" rows="5" cols="45" class="large-text"> 236 <?php echo esc_textarea( get_ network_option( 'first_page' ) ) ?></textarea>236 <?php echo esc_textarea( get_site_option( 'first_page' ) ) ?></textarea> 237 237 <p class="description" id="first-page-desc"> 238 238 <?php _e( 'The first page on a new site.' ) ?> … … 244 244 <td> 245 245 <textarea name="first_comment" id="first_comment" aria-describedby="first-comment-desc" rows="5" cols="45" class="large-text"> 246 <?php echo esc_textarea( get_ network_option( 'first_comment' ) ) ?></textarea>246 <?php echo esc_textarea( get_site_option( 'first_comment' ) ) ?></textarea> 247 247 <p class="description" id="first-comment-desc"> 248 248 <?php _e( 'The first comment on a new site.' ) ?> … … 253 253 <th scope="row"><label for="first_comment_author"><?php _e( 'First Comment Author' ) ?></label></th> 254 254 <td> 255 <input type="text" size="40" name="first_comment_author" id="first_comment_author" aria-describedby="first-comment-author-desc" value="<?php echo get_ network_option( 'first_comment_author') ?>" />255 <input type="text" size="40" name="first_comment_author" id="first_comment_author" aria-describedby="first-comment-author-desc" value="<?php echo get_site_option('first_comment_author') ?>" /> 256 256 <p class="description" id="first-comment-author-desc"> 257 257 <?php _e( 'The author of the first comment on a new site.' ) ?> … … 262 262 <th scope="row"><label for="first_comment_url"><?php _e( 'First Comment URL' ) ?></label></th> 263 263 <td> 264 <input type="text" size="40" name="first_comment_url" id="first_comment_url" aria-describedby="first-comment-url-desc" value="<?php echo esc_attr( get_ network_option( 'first_comment_url' ) ) ?>" />264 <input type="text" size="40" name="first_comment_url" id="first_comment_url" aria-describedby="first-comment-url-desc" value="<?php echo esc_attr( get_site_option( 'first_comment_url' ) ) ?>" /> 265 265 <p class="description" id="first-comment-url-desc"> 266 266 <?php _e( 'The URL for the first comment on a new site.' ) ?> … … 274 274 <th scope="row"><?php _e( 'Site upload space' ) ?></th> 275 275 <td> 276 <label><input type="checkbox" id="upload_space_check_disabled" name="upload_space_check_disabled" value="0"<?php checked( get_ network_option( 'upload_space_check_disabled' ), 0 ) ?>/> <?php printf( __( 'Limit total size of files uploaded to %s MB' ), '</label><label><input name="blog_upload_space" type="number" min="0" style="width: 100px" id="blog_upload_space" aria-describedby="blog-upload-space-desc" value="' . esc_attr( get_network_option('blog_upload_space', 100) ) . '" />' ); ?></label><br />276 <label><input type="checkbox" id="upload_space_check_disabled" name="upload_space_check_disabled" value="0"<?php checked( get_site_option( 'upload_space_check_disabled' ), 0 ) ?>/> <?php printf( __( 'Limit total size of files uploaded to %s MB' ), '</label><label><input name="blog_upload_space" type="number" min="0" style="width: 100px" id="blog_upload_space" aria-describedby="blog-upload-space-desc" value="' . esc_attr( get_site_option('blog_upload_space', 100) ) . '" />' ); ?></label><br /> 277 277 <p class="screen-reader-text" id="blog-upload-space-desc"> 278 278 <?php _e( 'Size in megabytes' ) ?> … … 284 284 <th scope="row"><label for="upload_filetypes"><?php _e( 'Upload file types' ) ?></label></th> 285 285 <td> 286 <input name="upload_filetypes" type="text" id="upload_filetypes" aria-describedby="upload-filetypes-desc" class="large-text" value="<?php echo esc_attr( get_ network_option( 'upload_filetypes', 'jpg jpeg png gif' ) ) ?>" size="45" />286 <input name="upload_filetypes" type="text" id="upload_filetypes" aria-describedby="upload-filetypes-desc" class="large-text" value="<?php echo esc_attr( get_site_option( 'upload_filetypes', 'jpg jpeg png gif' ) ) ?>" size="45" /> 287 287 <p class="description" id="upload-filetypes-desc"> 288 288 <?php _e( 'Allowed file types. Separate types by spaces.' ) ?> … … 294 294 <th scope="row"><label for="fileupload_maxk"><?php _e( 'Max upload file size' ) ?></label></th> 295 295 <td> 296 <?php printf( _x( '%s KB', 'File size in kilobytes' ), '<input name="fileupload_maxk" type="number" min="0" style="width: 100px" id="fileupload_maxk" aria-describedby="fileupload-maxk-desc" value="' . esc_attr( get_ network_option( 'fileupload_maxk', 300 ) ) . '" />' ); ?>296 <?php printf( _x( '%s KB', 'File size in kilobytes' ), '<input name="fileupload_maxk" type="number" min="0" style="width: 100px" id="fileupload_maxk" aria-describedby="fileupload-maxk-desc" value="' . esc_attr( get_site_option( 'fileupload_maxk', 300 ) ) . '" />' ); ?> 297 297 <p class="screen-reader-text" id="fileupload-maxk-desc"> 298 298 <?php _e( 'Size in kilobytes' ) ?> … … 313 313 <td> 314 314 <?php 315 $lang = get_ network_option( 'WPLANG' );315 $lang = get_site_option( 'WPLANG' ); 316 316 if ( ! in_array( $lang, $languages ) ) { 317 317 $lang = ''; … … 340 340 <td> 341 341 <?php 342 $menu_perms = get_ network_option( 'menu_items' );342 $menu_perms = get_site_option( 'menu_items' ); 343 343 /** 344 344 * Filter available network-wide administration menu options.
Note: See TracChangeset
for help on using the changeset viewer.