Top

App Discount isn't Applying in the Cart

Usually when this occurs it's because the browser isn't actually on the cart page (yourshop.myshopify.com/cart), but rather on a page that happens to show the contents of the cart through a preview, such as a modal window or a window that "slides" down from the top of the page.  This functionality is often associated with an "AJAX add to cart function", which is theme functionality that keeps the user on the product page when the add to cart button is clicked, which then may display the cart preview after it runs.  By default the app's discounts won't automatically apply in a cart preview.  More information about this can be found in the "Product Bundles not applying a discount in a cart preview" section below.

Another less common cause of Product Bundles not updating the price of your products in the cart it might be because your shop is using CloudFlare.  Product Bundles also uses CloudFlare and by default when both the shop and the app are using it, Product Bundles doesn't apply its discount.  For more information about this can be found in the "Product Bundles not applying a discount due to CloudFlare" section below.

 

Product Bundles not applying a discount in a cart preview

The app was developed to check if someone is eligible for a discount, and if so apply said discount, in the actual cart page.  For the most part this is because the discount functionality needs a page load, which traditionally would happen when a user is directed to the cart page from the product page after the add to cart button is clicked.  Some theme functionality, like an AJAX add to cart function, prevents the required page load by keeping the user on the product page, and actually prevents the discount functionality from taking place.

The easiest solution would be to simply disable said functionality, such as the AJAX add to cart functionality, and have the user directed to the cart page (which would disable any associated cart preview) where the discounts would apply.

Another solution would be to force a page refresh when the add to cart button is clicked, which would trigger the app's discount functionality.  The user would be able to stay on the product page, which is at it's core the point of the AJAX add to cart function, but this would likely disrupt any kind of cart preview from immediately showing up.

Yet another solution would be to change the "checkout" button in the cart preview functionality (if applicable) to direct the user to the cart page where the discount would apply, instead of to the checkout page which would bypass the app's discount functionality.  The app discounts wouldn't appear in the initial cart preview, but they'd still apply in the cart page.

What exactly can be done depends upon the exact theme functionality in question.  If this situation applies to you then feel free to contact us and we can consult and help implement a solution that works for you that also allows for the Product Bundles functionality.

 

Examples of AJAX add to cart functions:

 

 

Product Bundles not applying a discount due to CloudFlare

The following instructions will help guide you through correcting this issue. However if you find that you are still having issues, please make sure to inform our Support Wizards here and we will assist you further.

 
 log in to CloudFlare, and navigate to Page Rules tab:
 
 
Add a new rule as shown below, make sure that Custom Caching is set to Bypass cache.
 
 
Scroll down and save the rule by clicking 'Save as Draft' or 'Save and Deploy':

 

 

Have more questions? Submit a request