MyBB Community Forums

Full Version: Fix for MyBB emails going to spam box
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
If all of your emails, sent from php mail, or sendmail, are being put straight into the spam box, the way I fixed it was by changing line 318 in inc/class_mailhandler.php from :
"$this->headers .= "X-Mailer: MyBB."{$this->delimiter}";"
to:
$this->headers .= "X-Mailer: PHP/".phpversion()."{$this->delimiter}";

Now all of the mail, whether it be a user emailing another user, or a mass email, will go to the inbox, rather than the spam box.
i'll try it and thx for share bro
Thanks for sharing, didn't work for me, hotmail users still aren't getting them. We need an unsubscribe header like Mailchimp use http://stackoverflow.com/questions/43658...der-how-to
Note that this does disclose your PHP version, which is arguably not a smart thing to do if you're ever running a potentially out of date version.

Work on DKIM, SPF, and DMARC records first. Fixing those also helps reduce the spam score of messages significantly.