woocommerce_update_option
Deprecated since 2.4.0 - doesn't allow manipulation of values!. It is no longer supported and may be removed in future releases. It is recommended to replace this hook with the same one.
Fire an action before saved.
Usage
add_action( 'woocommerce_update_option', 'wp_kama_woocommerce_update_option_action' );
/**
* Function for `woocommerce_update_option` action-hook.
*
* @param $option
*
* @return void
*/
function wp_kama_woocommerce_update_option_action( $option ){
// action...
}
- $option
- -
Changelog
| Deprecated since 2.4.0 | - doesn't allow manipulation of values! |
Where the hook is called
woocommerce_update_option
woocommerce_update_option
woocommerce_update_option
woocommerce_update_option
woocommerce/includes/admin/class-wc-admin-settings.php 1064
do_action( 'woocommerce_update_option', $option );
woocommerce/includes/class-wc-ajax.php 4711
do_action( 'woocommerce_update_option', $option );
woocommerce/includes/class-wc-ajax.php 4715
do_action( 'woocommerce_update_option', $option );
woocommerce/includes/gateways/bacs/class-wc-gateway-bacs.php 272
do_action( 'woocommerce_update_option', array( 'id' => 'woocommerce_bacs_accounts' ) );
woocommerce/includes/abstracts/abstract-wc-settings-api.php 237
do_action( 'woocommerce_update_option', array( 'id' => $option_key ) ); // phpcs:ignore WooCommerce.Commenting.CommentHooks.MissingHookComment
Where the hook is used in WooCommerce
woocommerce/includes/tracks/events/class-wc-settings-tracking.php 76
add_action( 'woocommerce_update_option', array( $this, 'add_option_to_list' ) );