How to check if discount is applied (and show notification bar before checkout)

How to check if discount is applied (and show notification bar before checkout)

Mystform
Visitor
3 0 0

I want to display notification bar on top of every page if discount is applied (mostly for email marketing and automatically applied discounts), but I can't find a way to check if a discount is active (no need to display any dynamic, just "Your discount is applied"). Or atleast display it on first page after redirection. Is it possible to check if url contains a string without javascript?

Replies 4 (4)

LitExtension
Shopify Partner
4892 1004 1171

Hi @Mystform,

You can only check the discount while on the cart or checkout page, you can't check it on every page.

Can you explain your requirement more, I will help you to check it.

 

LitExtension - Shopping Cart Migration Expert
Check out our Shopify migration app to migrate your online store to Shopify
Contact us:
- Email: contact@litextension.com
ThangCQ
Shopify Partner
34 3 7

I meet same problem. I just want that when customer apply a discount automatically through automatic url discount, the text "discount is applied" will appear in banner. I've use 

"cart.discount_applications" but it's not work correctly (customer have to go to checkout page and comeback for it to appear). Do you have any suggestion for this case.
Thank you in advance
BMekiker
Visitor
1 0 0

I would like to do something similar. Have you found a solution for this?

HH8
Visitor
2 0 0

I've been looking everywhere for this....has anyone figured out how to do this? seems like a basic function. When someone uses a shareable discount code link a pop up and/or banner greets them letting them know their promo has applied