AI Verified

Name

Change COD default order status to On-hold

About

Makes On-hold the orders using COD and BACS

Language

PHP

Rating

Voted: 0 by 0 user(s)

Codevault

Jaypee

Scroll down to see more snippets from this codevault.

Wordpress Compatability

The author has indicated that this snippet is compatable up to wordpress version: older

Our AI bot has checked this snippet is compatable up to wordpress version: 6.1

Code Snippet Plugin Sync

Free & Pro

Download this snippet by clicking the download button, then head over to the Code Snippet Plugin settings in your wordpress admin dashboard, select the import menu then upload this file to import into your wordpress site.

Pro Only (Coming Soon)

You will be able to click a button and sync this snippet to your wordpress site automatically and from your dashboard manage all code snippets across all your wordpress sites that have the Code Snippets Pro plugin installed.

Website/ Profile URL:

https://maglacasdigital.com/

History

Last modified:

21/11/2022

Important Note

This snippet has the following status:

AI Verified

This snippet has been tested by our AI bot, see any comments below.

AI Bot Comments:

Found 0 vulnerabilities

Change COD default order status to On-hold

 
                    
1/*
2* Makes On-hold the orders using COD and BACS
3*/
4add_filter( 'woocommerce_bacs_process_payment_order_status', 'set_process_payment_order_status_on_hold', 10 );
5add_filter( 'woocommerce_cod_process_payment_order_status', 'set_process_payment_order_status_on_hold', 10 );
6 
7function set_process_payment_order_status_on_hold( $status ) {
8 return 'on-hold';
9}

0

Related Snippets

Please see some snippets below related to this snippet..

WooCommerce

AI Verified

0

WooCommerce Hide Product Meta (SKU, Categories, Tags)

Added: 1 year ago

Last Updated: 1 year ago

Typically, the product’s SKU, categories and tags it belongs to, will appear under the Add To Cart call to action button. This information in known as the product meta and this guide shows you how to...

WooCommerce

AI Verified

0

Add an Empty Cart Button to WooCommerce Cart

Added: 3 months ago

Last Updated: 3 months ago

By default, WooCommerce allows users to remove items from their cart individually. This tutorial demonstrates how to implement a single-button solution on the cart page, enabling users to clear the en...

WooCommerce

AI Verified

0

WooCommerce Percentage Checkout Admin/Handling Fee

Added: 1 year ago

Last Updated: 1 year ago

A little warning, unexpected fees at checkout can put some users off and some payment gateways do not allow custom additional fees. Passing on fees and surcharges may not be legal in your location so...

Other Snippets in this Codevault

These are some popular snippets from this users codevault..

WooCommerce

AI Verified

1

Hide Order Notes

Added: 1 year ago

Last Updated: 10 months ago

Hide Order notes in WooCommerce check out page.

WooCommerce

AI Verified

0

Change COD default order status to On-hold

Added: 1 year ago

Last Updated: 1 year ago

Makes On-hold the orders using COD and BACS

JavaScript

Unverified

0

Text fields makes autocomplete off

Added: 1 year ago

Last Updated: 1 year ago

Make text field autocomplete off using the Fluent forms plugin