Product Icon

Smart Coupons for WooCommerce

Boost sales and customer loyalty. Create advanced discounts, sell gift cards, set BOGO deals, give store credits, and all types of rule based dynamic discounts with this all-in-one Smart Coupons plugin for WooCommerce.

Coupon Valid on Days

This feature would be awesome for stores that have a special offer on set days of week.

Like JustEat have a Two for Tuesday promo, many stores may find this a handy Feature

Here is an example on how i envision it, Please enjoy the code.

// Add valid days checkboxes to the coupon admin page
add_action( ‘woocommerce_coupon_options’, ‘add_valid_days_field_to_coupon’ );
function add_valid_days_field_to_coupon() {
$days_of_week = [‘Monday’, ‘Tuesday’, ‘Wednesday’, ‘Thursday’, ‘Friday’, ‘Saturday’, ‘Sunday’];
$valid_days = get_post_meta( get_the_ID(), ‘valid_days’, true );
if ( ! is_array( $valid_days ) ) {
$valid_days = [];
}
?>

<input type="checkbox" name="valid_days[]" value="”
/>

Author

ukcandybox

Current Status

Open

Last updated: October 24, 2024

0 comments

Log in to comment on this feature request.

Use of your personal data
We and our partners process your personal data (such as browsing data, IP Addresses, cookie information, and other unique identifiers) based on your consent and/or our legitimate interest to optimize our website, marketing activities, and your user experience.