Rynald0s
(@rynald0s)
Automattic Happiness Engineer
Howdy!
You can use the following code that is found here:
https://metorik.com/blog/autocomplete-all-the-orders-in-woocommerce
add_action( 'woocommerce_thankyou', 'bryce_wc_autocomplete_order' );
function bryce_wc_autocomplete_order( $order_id ) {
// Only continue if have $order_id
if ( ! $order_id ) {
return;
}
// Get order
$order = wc_get_order( $order_id );
// Update order to completed status
$order->update_status( 'processing' );
}
I just replaced completed with processing
This custom code should be added to your child theme’s functions.php file or via a plugin that allows custom functions to be added, such as Code Snippets. Please don’t add custom code directly to your parent theme’s functions.php file as this will be wiped entirely when you update.
Cheers!
it works. i had a wrong plugin for css. thanks a lot