How to solve loading issue while select payment method on checkout page in wordpress

WordPress checkout issue

If you are a WordPress user and working on checkout page then you must be getting this error once a time.

Checkout page where the customer has an option to select a different different payment method and they are using their suitable payment method.

Now the owner of an e-commerce website created different shipping charges based on the payment method and Pincode OR they have integrated any shipping plugin based on payment method.

That means whenever a user will select payment method the charges will be updated based on given condition but what is required to see that effect.

The Loader

Yes if the loader does not load then how the customer will see the changes in price. so this is the issue we are getting when some of the themes did not support the loader or it has not the loader script.

Let’s see How to solve loading issue while select payment method on checkout page in WordPress.

So here is the script which to enabled the loader on checkout page while changing the payment method.

You have to put this script on function.php file to enable this.

add_action( 'wp_footer', 'enqueue_smartcod_js', 100 );

function enqueue_smartcod_js() {
	ob_start(); ?>
	<script type="text/javascript">
	jQuery( document ).ready( function($) {
		$( 'body' ).on( 'change', 'input[name=payment_method], #shipping_state, #billing_state', function() {
			$( 'body' ).trigger( 'update_checkout' );

		$( 'body' ).on( 'focusout', '#billing_postcode, #shipping_postcode, #shipping_city, #billing_city', function() {
			$( 'body' ).trigger( 'update_checkout' );

If you still have an issue, please do comment below.

Thank you for reading.

You Might Be Interested in This Also:

How to Become a WordPress Developer?

How to get Organic traffic on WordPress Website?

Auto Image Optimization in WordPress.

How to Install & Setup WordPress on Cpanel?

How to Solve Update issue on WordPress Website?

List of WordPress Database Table & its Importance.

How to Update WordPress version Automatically?

Top 5 Free SEO Friendly News Paper WordPress Theme.

Free WhatsApp Chat Plugin for WordPress website.

What are Plugins in WordPress?

How to remove extra Tabs from Product Page in WordPress woo-commerce.



Please enter your comment!
Please enter your name here