• Is there a way to check to see if coupon code is applied and remove the free gift? everything I code tends to break the plugin by messing up the css and not showing any of the products. I have been trying to use a if else statement.
    add_action(‘woocommerce_before_cart_table’, ‘apply_product_on_coupon’);
    function apply_product_on_coupon( ) {
    global $woocommerce;

    if( $woocommerce->cart->applied_coupons ) {
    echo ‘No Free product’;
    }
    }
    ?> else do plugin.

    https://www.ads-software.com/plugins/woocommerce-multiple-free-gift/

  • The topic ‘check for coupon code’ is closed to new replies.