Skip to Content

Christos Pechlevanoudis

Personal website

  • Home
  • Blog
  • My CV
  • Plugins
  • Contact
Home Blog Best Coding practises Woocommerce – Update checkout on method payment change
Best Coding practises

Woocommerce – Update checkout on method payment change

Pexle ChrisUpdated on May 28, 2021May 28, 2021
add_action( 'wp_footer', 'pexlechris_custom_checkout_jqscript' );
function pexlechris_custom_checkout_jqscript() {
	if ( is_checkout()) :
	?>
	<script type="text/javascript">
	jQuery( function($){
		$('form.checkout').on('change', 'input[name="payment_method"]', function(){
			$(document.body).trigger('update_checkout');
		});
	});
	</script>
	<?php
	endif;
}

Post Navigation

How to recursive left trim a string in PHP
How to recursive left trim a string in PHP
How to setup product quantity min, max and step in woocommerce
How to setup product quantity min, max and step in woocommerce

Related Post

How to deny php execution in specific folders and with specific file names

How to add PHP Hooks in your WordPress Site

PHP tricks and tips

Using trim/ltrim/rtrim php functions with 2 parameters may cause unexpected outputs

How to access WordPress Database from your Dashboard

PHP tricks and tips

How to recursive left trim a string in PHP

Recent Posts

  • Using trim/ltrim/rtrim php functions with 2 parameters may cause unexpected outputs
  • How to access WordPress Database from your Dashboard
  • How to add PHP Hooks in your WordPress Site
  • New File Manager Plugin
  • Web Development Academy by CollegeLink

Categories

  • Best Coding practises
  • Promotions
  • Techy news
  • Tips for Freelancers
  • WordPress news

About me

  • Explore my WordPress Plugins
  • View my CV
  • Contact me
info@pexlechris.dev | 699 705 7373
© Copyright 2023 Christos Pechlevanoudis. All Rights Reserved.