Why are price add-ons or other data missing from customer orders?

There are a few reasons why the Virtual Option data or price add-ons are not getting added to customers’ orders.

Your theme has an AJAX cart

To top

An AJAX cart is a feature that will send the product page data to the cart without navigating away to the cart page. Some themes will display a pop up window to notify the customer that the item was added to the cart. Our app is not compatible with these features and will try to disable them if necessary.

Your theme has a drawer style cart

To top

Sometimes instead of a pop up window to notify the customer that a product has been added to the cart, there will be a drawer style cart that slides in from the right side. Many times these drawer style carts have checkout buttons which bypass the cart page and prevent the Virtual Option data from being added correctly. The drawer style carts can often be triggered by cart icon buttons in the header. Our app will attempt to disable drawer style carts.

Price Add-ons are getting deleted on slower connections

To top

In the cart page our app takes a moment to load. With slower connections this may take longer and if the customer checks out before our app has loaded then the price add-ons will get deleted in the checkout.

Your customers have JavaScript disabled

To top

Our app requires JavaScript to run. While JavaScript is enabled in all browsers by default, some people choose to turn it off for various reasons. Shopify will still allow customers to checkout even without JavaScript. If this is causing problems for you, here is a way to fix it.

You’ll need to go edit your current theme by going to Online Store -> Actions -> Edit Code

Next, drill down into the templates to find your add to cart button

In the Minimal theme, I found it by going through these templates:

Templates/product.liquid

Sections/product-template.liquid

<button type="submit" name="add" id="AddToCart" class="btn {{ btn_class }}{% if section.settings.enable_payment_button %} btn--secondary{% endif %}">
<span id="AddToCartText">{{ 'products.product.add_to_cart' | t }}</span>
</button>

To disable the add to cart button on every product, add the disabled attribute to the button.
Our app will enable the add to cart button.
You should only do this if our app is running on every product:

<button disabled type="submit" name="add" id="AddToCart" class="btn {{ btn_class }}{% if section.settings.enable_payment_button %} btn--secondary{% endif %}">
<span id="AddToCartText">{{ 'products.product.add_to_cart' | t }}</span>
</button>

To only disable the add to cart button on certain products, you can use a liquid conditional statement:

<button {% if product && product.handle == 'teapot' %}disabled{% endif %} type="submit" name="add" id="AddToCart" class="btn {{ btn_class }}{% if section.settings.enable_payment_button %} btn--secondary{% endif %}">
<span id="AddToCartText">{{ 'products.product.add_to_cart' | t }}</span>
</button>

To add a message for people with JavaScript disabled, add this after the add to cart button:

<noscript>You need to enable JavaScript to purchase this item.</noscript>
Was this article helpful?
Dislike 0

Pin It on Pinterest