Remove WooCommerce Password Strength Meter

WooCommerce

One friend of mine signed up for new account. Actually, I invited him to signup for an account using “REGISTER” form that I created in this post so that we could test it one more time. He complained that I couldn’t change his password because the web site thinks his password is so weak (even it isn’t he thought). I googled and found the reason. It’s due to new feature introduced in WooCommerce 2.5: password strength meter. By default, user needs to use strong password for security purpose.

Remove WooCommerce Password Strength Meter

My very first user has priority so I need to remove it so that he can change his password. I added this function in my plugin.

function wc_ninja_remove_password_strength() {
if ( wp_script_is( ‘wc-password-strength-meter’, ‘enqueued’ ) ) {
wp_dequeue_script( ‘wc-password-strength-meter’ );
}
}
add_action( ‘wp_print_scripts’, ‘wc_ninja_remove_password_strength’, 100 );

Credit: https://nicola.blog/2016/01/27/remove-the-password-strength-meter-on-the-checkout-page/


Leave a Reply