Skip to content

Instantly share code, notes, and snippets.

@kaushiksomaiya
Created May 16, 2020 17:09
Show Gist options
  • Save kaushiksomaiya/255f603c49fac54c4b5f4631225e716c to your computer and use it in GitHub Desktop.
Save kaushiksomaiya/255f603c49fac54c4b5f4631225e716c to your computer and use it in GitHub Desktop.
Auto Update Cart on Quantity Change in Woocommerce
<script type="text/javascript">
jQuery( document ).ready(function() {
jQuery(document).on("change", "input.qty", function(){
jQuery('.woocommerce-cart-form button[name="update_cart"]').click();
});
});
</script>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment