Home Website News Articles Standard Post

Standard Post

How to Disable the Password Reset Function in WordPress

If your WordPress website has registration enabled, but you don't want users to reset their passwords via the password recovery feature, you can use the following code to disable the password reset function. Add the following code to your theme's functions file. If you don't know how to add it, see: How to Safely Add Code to functions.php: Code Snippet…

Posted on November 19, 2019 About 1 minute read

If your WordPress website has registration enabled, but you don't want users to reset their passwords via the password recovery feature, you can use the following code to disable the password reset function.

Add the following code to your theme's functions file. If you don't know how to add it, see:Safe Method to Add Code to the functions.php File: Code Snippets

function disable_password_reset() {
	return false;
}
add_filter ( 'allow_password_reset', 'disable_password_reset' );

After disabling, when users click 'Forgot Password,' they will be prompted that password setting is unavailable.

5/5 - (1 vote)
Previous How to Set Image Link to Media File When Publishing a Post in WordPress 5.3 Continue reading content around the same timeline. Next 7 WordPress Database Plugins for _Cleaning_Optimizing_Resetting_Repairing_Searching View the next related tutorial or experience.

AI Website Building Assistant

🤖
Hello! I am the Naibabiji AI Assistant. How can I help you?
Quick Consultation: