How to add "add to cart" button on my shopify debut theme

Solved
Lovelyn12
Excursionist
39 1 3

Hello everyone!

 

I really need your help. I don't know how to add "add to cart" button on our shopify store using debut theme. when I use my mobile I can't able to proceed to check out. Please help to fix this issue.

 

Thanks a lot.

0 Likes
Jasoliya
Shopify Expert
4298 569 1072

You want to add "Add to cart" button collection page? or any specific section.

Want to modify or custom changes on store hire me.
If helpful then please Like and Accept Solution.
Email: jasoliyabrijesh123@gmail.com Or WhatsApp Or Skype: jasoliya.brijesh
Want to get Free review and advice for sale on store ?? just text me here
0 Likes
Jasoliya
Shopify Expert
4298 569 1072

Hi,

Follow this:

1. Go to Online Store->Theme->Edit code
2. Asset->theme.scss->paste bellow code in bottom of file

#footer-newsletter button:hover {color:black; background-color: white;}

Note: If not work then send me your store url.

Want to modify or custom changes on store hire me.
If helpful then please Like and Accept Solution.
Email: jasoliyabrijesh123@gmail.com Or WhatsApp Or Skype: jasoliya.brijesh
Want to get Free review and advice for sale on store ?? just text me here
0 Likes
Lovelyn12
Excursionist
39 1 3

Here is my store url https://boutq.com/


@Jasoliya wrote:

Hi,

Follow this:

1. Go to Online Store->Theme->Edit code
2. Asset->theme.scss->paste bellow code in bottom of file

#footer-newsletter button:hover {color:black; background-color: white;}

Note: If not work then send me your store url.


 

0 Likes
Lovelyn12
Excursionist
39 1 3

Screenshot 2019-06-24 15.45.23.png

0 Likes
Jasoliya
Shopify Expert
4298 569 1072

This is an accepted solution.

Follow this:

Add this button in snippet->product-grid.liquid 

<input type="button" class="btn ad_to_cart" var_id="{{ product.selected_or_first_available_variant.id }}">

Add this js in asset->theme.js

$(document).on('click','.ad_to_cart',function(){
  var var_id=$(this).attr('var_id');
  $.ajax({
    type: 'POST',
    url: '/cart/add.js',
    data: {
      quantity: 1,
      id: var_id
    },
    dataType: 'json', 
    success: function (data) { 
       
    } 
  });
})
Want to modify or custom changes on store hire me.
If helpful then please Like and Accept Solution.
Email: jasoliyabrijesh123@gmail.com Or WhatsApp Or Skype: jasoliya.brijesh
Want to get Free review and advice for sale on store ?? just text me here
theswirlbox
New Member
1 0 0

Hi @Jasoliya , I had the same query and used your solution, which worked. Thanks for that! :) The only issue is that when I click Add to Cart, although the product gets added to the cart, there is no notification. I am using debut theme and when I go to product page and add to cart, I see a little notification at the top right corner of the store notifying me the product is in the cart and I can choose to go to the cart from there. Could you help me adding this notification feature to the code you have mentioned?

Thanks

0 Likes
Jasoliya
Shopify Expert
4298 569 1072

basically you have to find code in debut theme where theme notification popup but you can show simple notification by this:

$.ajax({
    type: 'POST',
    url: '/cart/add.js',
    data: {
      quantity: 1,
      id: var_id
    },
    dataType: 'json', 
    success: function (data) { 
       alert('Added to cart');
    } 
  });

Here you can add "alert"

Want to modify or custom changes on store hire me.
If helpful then please Like and Accept Solution.
Email: jasoliyabrijesh123@gmail.com Or WhatsApp Or Skype: jasoliya.brijesh
Want to get Free review and advice for sale on store ?? just text me here
mmarcus15
Tourist
5 0 1

@theswirlbox Did you ever figure this out? I am trying to accomplish the same exact feature of some kind of notification. I've scoured the internet and haven't been able to find anything yet, unfortunately.

0 Likes