I removed the UPDATE button from woocommerce cart and I am trying to get the cart updated on quantity change on both desktop and mobile. The following script makes the job but for some reason it only works once. Hope someone can help, thanks so much!
add_action( 'wp_footer', 'update_cart_qty' );
function update_cart_qty() {
if (is_cart()) {
?>
<script type="text/javascript">
jQuery('input.qty').change(function(){
jQuery("[name='update_cart']").trigger("click");
});
</script>
<?php
}
}