-
-
Save athaller/e00a259ff67185ab8644c61f15328ada to your computer and use it in GitHub Desktop.
Set the mail return path to mirror the sender in wp_mail to reduce likelihood of spam rejection
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
add_action( 'phpmailer_init', 'fix_my_email_return_path' ); | |
function fix_my_email_return_path( $phpmailer ) { | |
$phpmailer->Sender = $phpmailer->From; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment