Changeset 24120
- Timestamp:
- 04/29/2013 12:26:49 AM (11 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-admin/network/site-settings.php
r23567 r24120 50 50 switch_to_blog( $id ); 51 51 52 $c = 1;53 $count = count( $_POST['option'] );54 52 $skip_options = array( 'allowedthemes' ); // Don't update these options since they are handled elsewhere in the form. 55 53 foreach ( (array) $_POST['option'] as $key => $val ) { … … 58 56 if ( $key === 0 || is_array( $val ) || in_array($key, $skip_options) ) 59 57 continue; // Avoids "0 is a protected WP option and may not be modified" error when edit blog options 60 if ( $c == $count ) 61 update_option( $key, $val ); 62 else 63 update_option( $key, $val, false ); // no need to refresh blog details yet 64 $c++; 58 update_option( $key, $val ); 65 59 } 66 60 … … 124 118 if ( is_serialized( $option->option_value ) ) { 125 119 if ( is_serialized_string( $option->option_value ) ) { 126 $option->option_value = esc_html( maybe_unserialize( $option->option_value ) , 'single');120 $option->option_value = esc_html( maybe_unserialize( $option->option_value ) ); 127 121 } else { 128 122 $option->option_value = 'SERIALIZED DATA';
Note: See TracChangeset
for help on using the changeset viewer.