woocommerce_order_save_attribution_data
Run an action to save order attribution data.
Usage
add_action( 'woocommerce_order_save_attribution_data', 'wp_kama_woocommerce_order_save_attribution_data_action', 10, 2 ); /** * Function for `woocommerce_order_save_attribution_data` action-hook. * * @param WC_Order $order The order object. * @param array $params Unprefixed order attribution data. * * @return void */ function wp_kama_woocommerce_order_save_attribution_data_action( $order, $params ){ // action... }
- $order(WC_Order)
- The order object.
- $params(array)
- Unprefixed order attribution data.
Changelog
Since 8.5.0 | Introduced. |
Where the hook is called
woocommerce_order_save_attribution_data
woocommerce_order_save_attribution_data
woocommerce/src/Internal/Orders/OrderAttributionController.php 165
do_action( 'woocommerce_order_save_attribution_data', $order, $params );
woocommerce/src/Internal/Orders/OrderAttributionBlocksController.php 116
do_action( 'woocommerce_order_save_attribution_data', $order, $params );