• I have been using Code snippets for a long time and it has always been working great.

    But today I stumbled upon a code that did not work when I inputted it into Code snippets, at first I thought something was wrong with the code, but I then realized it worked if I added it directly into the theme functions.php

    add_filter( ‘woocommerce_checkout_coupon_message’, ‘bbloomer_have_coupon_message’);

    functionbbloomer_have_coupon_message() {

       return’ Testing text? Click here to enter your discount code‘;

    }

    ..why does the code above not work in Code snippets?
    I use the theme: Shoptimizer

    • This topic was modified 2 years, 6 months ago by henkesan.

The topic ‘Code not working in code snippets, only in functions.php’ is closed to new replies.