Debut Theme: Add to Cart button on homepage/collection pages

Solved
cdanielc
Tourist
16 0 1

Hi,

This question has been raised a few times, but I can't get it up and working (outdated posts?) and I have an additional question regarding the design. 

As I am using Debut theme there is by default no "add to cart" button below the products on the homepage/collection pages. I would like to add an "add to cart" button in the same style as if you would create a Buy button for an external site  (Sales Channels > Buy button > Create a buy button). Please find an image below.

Can anyone help me out? Thanks in advance!

Buy buttonBuy button




Replies 110 (110)
tjacobofficial
New Member
2 0 1

Hi there, I'm hoping you can help me with a similar issue. I've followed your instructions to add the cart button, but the buttons are laying right on top of the next row like pictured. Could you help with this? Jacob University Store password: awtsoh

 

Screenshot 2021-06-17 165226.png

KetanKumar
Shopify Partner
36500 3621 11763

@tjacobofficial 

sorry for that issue can you please try this 

1. Go to Online Store->Theme->Edit code
2. Asset->/theme.css ->paste below code at the bottom of the file.
this code apply for after 5 - 6 second

.product-card {margin-bottom: 10px;}
.product-card+form {margin-bottom: 30px;}
.product-card+form input {width: 100%;}

 

If helpful then please Like and Accept Solution.
Want to modify or custom changes on store Hire me.
- Feel free to contact me on bamaniyaketan.sky@gmail.com regarding any help
Shopify Partner | Skype : bamaniya.sky
PSD to Shopify | Shopify Design Changes | Shopify Custom Theme Development and Desing | Custom Modifications In to Shopify Theme | SEO & Digital Marketing
tjacobofficial
New Member
2 0 1

Wonderful, that's perfect! Thank you so much!

Firefly1
Tourist
14 0 2

Hi,

Is there a way to get this button inactive when the product is sold out?

sold.png

Thanks in Advance.

moonrise
Excursionist
12 0 4

Hello @KetanKumar 

I followed your customized code which you give about homepage add to cart button code. It worked very well but on mobile, the button is doesn't look very well. I want to resize add to cart button as a thinner. 

URL: onthologie.com

IMG_4509.jpeg

KetanKumar
Shopify Partner
36500 3621 11763

@moonrise 

Sorry you are facing this issue, it would be my pleasure to help you.

Welcome to the Shopify community!😊
Thanks for your good question.

Please share your site URL,
I will check out the issue and provide you a solution here.

If helpful then please Like and Accept Solution.
Want to modify or custom changes on store Hire me.
- Feel free to contact me on bamaniyaketan.sky@gmail.com regarding any help
Shopify Partner | Skype : bamaniya.sky
PSD to Shopify | Shopify Design Changes | Shopify Custom Theme Development and Desing | Custom Modifications In to Shopify Theme | SEO & Digital Marketing
moonrise
Excursionist
12 0 4

@KetanKumar 

On Desktop add to cart buttons are ok but on mobile look big. I want smaller or maybe thinner

https://www.onthologie.com/

KetanKumar
Shopify Partner
36500 3621 11763

@moonrise 

can you please confirm this look

KetanKumar_0-1625902404096.png

 

If helpful then please Like and Accept Solution.
Want to modify or custom changes on store Hire me.
- Feel free to contact me on bamaniyaketan.sky@gmail.com regarding any help
Shopify Partner | Skype : bamaniya.sky
PSD to Shopify | Shopify Design Changes | Shopify Custom Theme Development and Desing | Custom Modifications In to Shopify Theme | SEO & Digital Marketing
moonrise
Excursionist
12 0 4

I like the add to cart section like that but is there any way to remove quantity? @KetanKumar 

moonrise
Excursionist
12 0 4

Hi @KetanKumar 

I have been trying to find some solutions but couldn't find any. Would you help me, please?

mariavii
Tourist
4 0 1

Hi! I saw that you helped lot of people here. Could you please help me also, I want to have a "buy it now" button under the products on the home page and collection pages. 

Here's my url www.alofiepets.com 

Thanks 

 

KetanKumar
Shopify Partner
36500 3621 11763

https://shopify.dev/custom-storefronts/tools/buy-button

If helpful then please Like and Accept Solution.
Want to modify or custom changes on store Hire me.
- Feel free to contact me on bamaniyaketan.sky@gmail.com regarding any help
Shopify Partner | Skype : bamaniya.sky
PSD to Shopify | Shopify Design Changes | Shopify Custom Theme Development and Desing | Custom Modifications In to Shopify Theme | SEO & Digital Marketing
SaraAkil
Tourist
4 0 4

Hello,

 

I want to REMOVE the add to cart button from my collections and homepage. I want the button to appear only on each product page. Ive searched for the answer and couldnt find the solution please help

KetanKumar
Shopify Partner
36500 3621 11763

@SaraAkil 

Sorry you are facing this issue, it would be my pleasure to help you.

Welcome to the Shopify community!😊
Thanks for your good question.

Please share your site URL,
I will check out the issue and provide you a solution here.

If helpful then please Like and Accept Solution.
Want to modify or custom changes on store Hire me.
- Feel free to contact me on bamaniyaketan.sky@gmail.com regarding any help
Shopify Partner | Skype : bamaniya.sky
PSD to Shopify | Shopify Design Changes | Shopify Custom Theme Development and Desing | Custom Modifications In to Shopify Theme | SEO & Digital Marketing
KetanKumar
Shopify Partner
36500 3621 11763

@SaraAkil 

thanks for URL

can you try this code

1. Go to Online Store->Theme->Edit code
2. Asset->/theme.scss.liquid->paste below code at the bottom of the file.

.product-card form {
    display: none;
}

 

If helpful then please Like and Accept Solution.
Want to modify or custom changes on store Hire me.
- Feel free to contact me on bamaniyaketan.sky@gmail.com regarding any help
Shopify Partner | Skype : bamaniya.sky
PSD to Shopify | Shopify Design Changes | Shopify Custom Theme Development and Desing | Custom Modifications In to Shopify Theme | SEO & Digital Marketing
SaraAkil
Tourist
4 0 4

It worked! Finally! been going at it for 10 days! Thank you!

KetanKumar
Shopify Partner
36500 3621 11763

@SaraAkil 

its my pleasure to help us

 

If helpful then please Like and Accept Solution.
Want to modify or custom changes on store Hire me.
- Feel free to contact me on bamaniyaketan.sky@gmail.com regarding any help
Shopify Partner | Skype : bamaniya.sky
PSD to Shopify | Shopify Design Changes | Shopify Custom Theme Development and Desing | Custom Modifications In to Shopify Theme | SEO & Digital Marketing
Passiondepices
New Member
1 0 1

Hello @KetanKumar 

Thank you for this solution. It worked perfectly.

Is there any way that we can make the "Add to Cart" button not navigate away from the collections page and/or homepage?

For both mobile and desktop please. When we add from the product page, the user stays on the page and gets the "added to cart" notification as per below pic. We would like to keep it this way to reduce the number of clicks when people are browsing a collection and selecting multiple products to add.

Screen Shot 2021-09-21 at 2.09.49 PM.png

 

Here's the store link: www.passiondepices.com

Thank you!

lymie
New Member
2 0 1

Hello Ketan, 

Thank you so much for your input. I have followed your instructions and I have successfully implemented the add to cart button under the featured product on my homepage. However, I have not been able to code the variant selector. 

My website is www.foodslicerpro.com

Can you please help?