Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Disable wordpress 4.3 send email when password has been changed

Tags:

php

wordpress

Wordpress developers say: You can disable these e-mails via the send_pass_change_email and send_email_change_email filters by setting them to false.

I have added these lines into my plugin but it doesn't help:

function no_email_pass_change(){ return false; }
add_filter( 'send_pass_change_email' , 'no_email_password_change');

function no_email_email_change(){ return false; }
add_filter( 'send_email_change_email' , 'no_email_email_change');

function no_email_password_change(){ return false; }
add_filter( 'wp_password_change_notification' , 'no_email_password_change');

Also I tried these:

add_filter( 'send_pass_change_email', '__return_false');
add_filter( 'send_email_change_email', '__return_false');

But nothing helps. It is applicable only to WP 4.3. What am I doing wrong?

like image 434
qqruza Avatar asked Aug 18 '15 21:08

qqruza


People also ask

How do I stop WordPress from sending emails?

Upon activation, you need to visit the Settings » Notification e-mails page. This is where the plugin allows you to manage all WordPress notification emails including auto-update notifications. Simply scroll down to the auto-update options and uncheck the box next to the notifications that you want to disable.

How do I disable confirmation email for new users in WordPress?

The easiest way to disable the new user notification email in Wordpress is to use the Manage Notification E-mails plugin. This plugin will allow you to disable a slew of admin related emails. After installing and activating the plugin you'll see a new option in your settings for “Notification e-mails”.


1 Answers

Use the following:

  add_filter( 'send_password_change_email', '__return_false');

They put the wrong description in the documentation.

like image 190
qqruza Avatar answered Sep 24 '22 15:09

qqruza