does anyone know a way to disable the checkout button and top link until the customer has applied a coupon code?
it could be actually disabling the button itself, or it could be simply redirecting back to the cart. but i don’t want the customer to be able to proceed to checkout until they have selected a coupon.
I need to do this because i’m using coupon codes to create the price for all items in the cart at the same level depending on which coupon code is selected. (I’ve tweaked the coupon.phtml to input as a drop-down list instead of text entry) now everything is working except it is possible for the customer to proceed to the checkout without selecting a coupon, and thus without selecting a price level.
there must be a rather simple ?php if statement that i can use to either turn the button on and of or link back to the cart, but i’m lost as to where to put it or what to do.
it seems that it might have something to do with this line from coupon.phtml: <?php if(!strlen($this->getCouponCode())): ?>
but i just don’t know and i’ve tried all of the trial and error that i can handle.
if any of you coding veterans have a solution for me, or even just a pointer, I would be grateful.
to clarify, i simply want to say:
if coupon code = “no entry”, then disable checkout
but i don’t know how or where to write it.