|
/ Documentation /Code Snippets/ How to Turn Off the Auto-fill of Checkout Fields?

How to Turn Off the Auto-fill of Checkout Fields?

You might be wondering how your billing information is getting pre-filled on the checkout page. Well, let me reveal this trick with you.

When you visit the checkout page and fill-out the billing or shipping information of the checkout fields. Just after filling out all the data, CartFlows automatically stores that information on your local system only. That means this data cannot be displayed unless and until some other user logins to your system and opens the checkout page.

This data is never transferred or stored on the server-side. This is stored just to provide ease of access to the end-users while placing the order next time or multiple times. This reduces the time re-entering that same data again and again. Instead, it will auto-filled from the locally stored data avoiding re-work.

There might be some cases in which you wish to disable this feature on your website and for the same we have provided the following filter –

/**
 * Filter to enable/disable the auto-fill of checkout fields 
 *
 * @param  string $allow having yes/no
 * @return string $allow yes or no
 */
add_filter( 'cartflows_allow_persistence', 'do_not_store_persistance_data', 10, 1 );

function do_not_store_persistance_data( $allow ){
	$allow = 'no';
	return $allow;
}

Note: Add the above filter to your child theme’s functions.php, here’s an article to help you Add Custom code.

Was this doc helpful?
What went wrong?

We don't respond to the article feedback, we use it to improve our support content.

Need help? Contact Support
On this page
Download is Just A Click Away!

Enter your email address and be the first to learn about updates and new features.

Free Cartflows Form - Popup

Download is Just A Click Away!

Enter your email address and be the first to learn about updates and new features.