Changeset 12164
- Timestamp:
- 11/11/2009 03:26:11 PM (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-includes/functions.php
r12128 r12164 523 523 $newvalue = maybe_serialize( $newvalue ); 524 524 525 do_action( 'update_option', $option_name, $oldvalue, $newvalue ); 525 526 $alloptions = wp_load_alloptions(); 526 527 if ( isset( $alloptions[$option_name] ) ) { … … 535 536 if ( $wpdb->rows_affected == 1 ) { 536 537 do_action( "update_option_{$option_name}", $oldvalue, $_newvalue ); 538 do_action( 'updated_option', $option_name, $oldvalue, $_newvalue ); 537 539 return true; 538 540 } … … 583 585 $value = maybe_serialize( $value ); 584 586 $autoload = ( 'no' === $autoload ) ? 'no' : 'yes'; 585 587 do_action( 'add_option', $name, $value ); 586 588 if ( 'yes' == $autoload ) { 587 589 $alloptions = wp_load_alloptions(); … … 602 604 603 605 do_action( "add_option_{$name}", $name, $value ); 606 do_action( 'added_option', $name, $value ); 607 604 608 return; 605 609 } … … 625 629 if ( is_null($option) ) 626 630 return false; 631 do_action( 'delete_option', $name ); 627 632 // expected_slashed ($name) 628 633 $wpdb->query( "DELETE FROM $wpdb->options WHERE option_name = '$name'" ); … … 636 641 wp_cache_delete( $name, 'options' ); 637 642 } 643 do_action( 'deleted_option', $name ); 638 644 return true; 639 645 }
Note: See TracChangeset
for help on using the changeset viewer.