Get rid of pop up shopping cart on Supply Theme

SophieFHAU
New Member
2 0 0

Hi all, I have no need for a shopping cart page on my store as I am only selling 1 thing.

I have managed to use code to eliminate the cart button in my header and change the text of my "add to cart" button to something else.. the only thing I can't find is how to stop the Cart Summary from popping up after clicking that button. I can find it for other themes but not for Supply. Need it to go straight to checkout after clicking that button.

Any help appreciated, thanks :)

Replies 5 (5)
Savannah_F
Shopify Staff
530 0 99

Hey, Sophie!

Savannah here from the Shopify Guru Team. 

You can do that by adding a code to your product-template.liquid. That's located in the Sections folder of your theme's coding. 

Look for the code that says,       

<form action="/cart/add" method="post" enctype="multipart/form-data" id="addToCartForm">

Make a space and add this code below that line:      

 <form action="/cart/add" method="post" enctype="multipart/form-data" id="addToCartForm"> 

Click save, and then navigate to Online Store>Themes in your admin again. Select 'Customize Theme," and then "General Settings." From the General Settings menu, make sure that your Cart is set to Page and not Modal. Click save and you should be all set!

Let me know if that does the trick, or if there's anything that I can clarify further!

Savannah | Shopify Guru
support@shopify.com
 

Savannah | Shopify 
 - Was my reply helpful? Click Like to let me know! 
 - Was your question answered? Mark it as an Accepted Solution
 - To learn more visit the Shopify Help Center or the Shopify Blog

SophieFHAU
New Member
2 0 0

Thanks Savannah, however both of those codes look the same? is it suppose to be like that? i'll give it a try :)

Savannah_F
Shopify Staff
530 0 99

Hey, Sophie!

My mistake there. The code you'll actually want to paste after that code would be this:

               

 <input type="hidden" name="return_to" value="/checkout" />


Let me know how that goes, and thanks for your patience. :) 

Savannah | Shopify Guru
support@shopify.com

Savannah | Shopify 
 - Was my reply helpful? Click Like to let me know! 
 - Was your question answered? Mark it as an Accepted Solution
 - To learn more visit the Shopify Help Center or the Shopify Blog

thumbprint
Tourist
8 0 5

I, too, would like to disable the shopping cart pop up, but your code doesn't work in my theme (Supply). And the code you say to paste it after doesn't exist. The only code that talks about the cart on that template are these two:

 

{% capture "form_class" -%}
addToCartForm{% if section.settings.enable_payment_button %} addToCartForm--payment-button{% endif %}
{%- endcapture %}

{%- capture "form_id" -%}addToCartForm-{{ section.id }}{%- endcapture -%}

 

AND

 

<div class="payment-buttons payment-buttons--{{ section.settings.add_to_cart_button_size }}">
<button type="submit" name="add" id="addToCart-{{ section.id }}" class="{{ btn_class }} btn--add-to-cart{% if section.settings.enable_payment_button %} btn--secondary-accent{% endif %}">
<span class="icon icon-cart"></span>
<span id="addToCartText-{{ section.id }}">{{ 'products.product.add_to_cart' | t }}</span>
</button>

Abhi111
Tourist
8 0 4

Hey .

 

Its 2021 and  i still want to remove the add to cart pop up in supply theme . I could find the code you mentioned at this time could you please update .