Make the WooCommerce Terms & Conditions checkbox checked by default

this code is working on woocommerce 3.x and it is test on
woocommerce 3.1.0 with WordPress 4.8

just go to function.php file on your theme and add this code


function razztech_wc_terms( $terms_is_checked ) { return true;}
add_filter( 'woocommerce_terms_is_checked', 'razztech_wc_terms', 10 );
add_filter( 'woocommerce_terms_is_checked_default', 'razztech_wc_terms', 10 );

and now it should check it by default

Advertisements

Leave a Reply :)

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s