- This topic has 3 replies, 3 voices, and was last updated 6 years, 1 month ago by .
Viewing 4 posts - 1 through 4 (of 4 total)
Viewing 4 posts - 1 through 4 (of 4 total)
- You must be logged in to reply to this topic.
WordPress Membership Plugin
Simple Membership Plugin › Forums › Simple Membership Plugin › Need to stop users getting emails
The plugin does exactly what I need to it to but I have one issue I’m trying to overcome:
I want to handle all user registration myself with no user interaction at all. Therefore, I would like to stop any WordPress emails going to the users’ email addresses, especially when their account first gets registerd.
I’ve tried the ‘Manage Notification Emails’ plugin but it seems to conflict with Simple Membership and new users are still receiving emails (I say conflicts because I’ve tried disabling SM and it then works fine). Is there another way I can do this? Quite happy to edit wp-config if that’s required.
Thank you
1. Are there ANY (at all) email messages that SWPM normally sends out, to members, that you WANT the to receive?
2. Is it important, that you put their email addresses into their profiles?
If the answer to BOTH questions is “no,” the easy way out is to set everyone’s email address domain to “example.com” which effectively sends all email to the bit-bucket. Or maybe use something in their profile like “member@gmail.com.example.com” which does the same thing.
Of course – the simplest answer is usually the best. Thank you!
filter for wp_mail when it tries to send, then nuke the email details if it meets your criteria
add_filter(‘wp_mail’,’disabling_swpm_emails’, 10,1);
function disabling_swpm_emails( $args ){
if ($args['subject']=='foo'){
$args['to']='';
$args['message']='';
}
return $args;
}