I have been searching for a while, this. I want to add an item via AJAX. When you add an item to a cart in Woocommerce the page reloads with the GET parameter add-to-cart="The current product ID".

I want to do it via AJAX. In the admin area is a checkbox to enable that featured that is labeled "Enable AJAX buttons to add to cart on the product list"

But it doesn't do anything, it stills reloading the page.

  • "Enable AJAX buttons to add to cart on the product list" g.translate
    – david
    Nov 22, 2012 at 1:11
  • @david as I wrote, I checked the enable AJAX button, but it doesn't do anything.
    – jepser
    Nov 23, 2012 at 1:59
  • This was no advice from my site, I was just translating your Spanish sentence :)
    – david
    Nov 23, 2012 at 9:39
  • @jepser did you ever find out the answer to this question? Its been bugging me aswell.
    – Lucky Luke
    Jan 29, 2013 at 19:31
  • Nope I have been waiting for someone that explain me this...
    – jepser
    Jan 30, 2013 at 17:29

1 Answer 1


are we talking about the single product view or the product archive pages (shop,categories)?

because the text beside the checkbox/option states, roughly translated:

»activate ajax-checkout-button on product archive pages«

and on all the installations i did so for, that is the way its working - ajax checkout on the archives, but not on the single view.

the latter you have to implement yourself or maybe you find a free plugin for that.

Follow up:

A basic example on how to use AJAX for the »add-to-cart«-functionality of woocommerce can be found here: Woocommerce - Add a product to cart programmatically via JS or PHP.

  • 1
    This is correct. The ajax add to cart option is only for product archives. To do add-to-cart via ajax on the single product page, you'd need to set up a jQuery click event and do the ajax call there. Aug 3, 2013 at 20:07

Not the answer you're looking for? Browse other questions tagged or ask your own question.