Changeset 12712 for trunk/wp-admin/options.php
- Timestamp:
- 01/12/2010 09:11:52 PM (15 years ago)
- Location:
- trunk/wp-admin
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-admin
-
Property
svn:ignore
set to
.categories.php.swp
-
Property
svn:ignore
set to
-
trunk/wp-admin/options.php
r12507 r12712 39 39 wp_die(__('Cheatin’ uh?')); 40 40 41 if ( is_multisite() && is_super_admin() && $_GET[ 'adminhash' ] ) { 42 $new_admin_details = get_option( 'adminhash' ); 43 if( is_array( $new_admin_details ) && $new_admin_details[ 'hash' ] == $_GET[ 'adminhash' ] && $new_admin_details[ 'newemail' ] != '' ) { 44 update_option( "admin_email", $new_admin_details[ 'newemail' ] ); 45 delete_option( "adminhash" ); 46 delete_option( "new_admin_email" ); 47 wp_redirect( get_option( "siteurl" ) . "/wp-admin/options-general.php?updated=true" ); 48 exit; 49 } else { 50 wp_redirect( get_option( "siteurl" ) . "/wp-admin/options-general.php?updated=false" ); 51 exit; 52 } 53 } 54 41 55 switch($action) { 42 56 … … 56 70 if ( 'options' == $option_page ) { 57 71 $options = explode(',', stripslashes( $_POST[ 'page_options' ] )); 72 if ( !is_super_admin() ) 73 wp_die( __( 'Not allowed here' ) ); 58 74 } else { 59 75 $options = $whitelist_options[ $option_page ]; … … 91 107 92 108 default: 109 if ( !is_super_admin() ) 110 wp_die( __( 'Not admin' ) ); 111 93 112 include('admin-header.php'); ?> 94 113 … … 100 119 <input type="hidden" name="action" value="update" /> 101 120 <input type='hidden' name='option_page' value='options' /> 121 <?php if ( is_multisite() ) { ?> 122 <p class="submit submit-top"> 123 <input type="submit" name="Submit" value="<?php _e('Save Changes') ?>" class="button-primary" /> 124 </p> 125 <?php } ?> 102 126 <table class="form-table"> 103 127 <?php … … 107 131 $disabled = ''; 108 132 $option->option_name = esc_attr($option->option_name); 133 if( $option->option_name == '' ) 134 continue; 109 135 if ( is_serialized($option->option_value) ) { 110 136 if ( is_serialized_string($option->option_value) ) {
Note: See TracChangeset
for help on using the changeset viewer.