This thread is over two years old and may be outdated. Please create a new thread if you need help, or email us if you have an active Premium license.

Updating the cart in Unwind causes the quantity control buttons disappear

9 years ago · Last reply by Alex S 9 years ago

Hello,

When the WooCommerce cart is visited on a site that uses the Unwind theme, each item in the cart has nice “+” and “-” buttons. When changes are made to the quantities and the Update Cart button is clicked, the page reloads and the above buttons disappear. This is reproducible on the official Unwind demo site, but for what it’s worth, my platform is WP 4.7.1, WooCommerce 2.6.12, Unwind 1.0.4.

This is our free support forum. Replies can take several days.

Need fast email support? Get SiteOrigin Premium

Replies

2
  1. peterk 9 years, 1 month ago

    Actually, the page is not fully reloaded, but only partially. As the cart form is updated in DOM, the code that inserts the buttons is not triggered. I have managed to work this around in the JS console by hooking the ‘updated_wc_div’ event and re-adding the buttons as in woocommerce.js (could the wrong approach, I have no WordPress dev experience).

    var $=jQuery.noConflict();
    $(document).on('updated_wc_div', function() { $('table.shop_table, .product form.cart').triggerQuantityButtons(); }); // button adding as borrowed from woocommerce.js in the GitHub repo
    
  2. Alex S Staff 9 years, 29 days ago

    Hi Peter,

    Thanks for letting us know about this. I’ve logged this as a bug in our issue tracker. We’ll investigate this as soon as possible and try come up with a fix.

Replies on this thread are closed.

Please create a new thread if you have a question, or purchase a SiteOrigin Premium license if you need one-on-one email support.

Have a different question or issue?

Start New Thread