Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save mehul0810/674b67ac4c6f14592bba5b69f56b452f to your computer and use it in GitHub Desktop.
Save mehul0810/674b67ac4c6f14592bba5b69f56b452f to your computer and use it in GitHub Desktop.
<script type="text/javascript">
jQuery( 'document' ).ready( function ($) {
$('#billing_postcode').on( 'focusout', function() {
$(this).trigger('update_checkout');
});
});
</script>
<?php
function mg_update_order_review_on_checkout( $post_data ) {
WC()->cart->calculate_shipping();
return;
}
add_action( 'woocommerce_checkout_update_order_review', 'mg_update_order_review_on_checkout', 10 );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment