woocommerce_order_action_ {action}
- by admin
- 0
“woocommerce_order_action_” used to define a callback for any order action occurred. It works once we changed the order action
So here we need to specify the action.
Usually used once we declare a new order status.
Sample code is for “invoice” action
add_action(‘woocommerce_order_action_invoice, ‘custom_order_action’ );
function custom_order_action($order_statuses)
{
/* code execute after action triggered */
}
“woocommerce_order_action_” used to define a callback for any order action occurred. It works once we changed the order action So here we need to specify the action. Usually used once we declare a new order status. Sample code is for “invoice” action add_action(‘woocommerce_order_action_invoice, ‘custom_order_action’ ); function custom_order_action($order_statuses) { /* code execute after action triggered…
“woocommerce_order_action_” used to define a callback for any order action occurred. It works once we changed the order action So here we need to specify the action. Usually used once we declare a new order status. Sample code is for “invoice” action add_action(‘woocommerce_order_action_invoice, ‘custom_order_action’ ); function custom_order_action($order_statuses) { /* code execute after action triggered…