Created
December 10, 2018 10:18
-
-
Save Dantali0n/37b9e935bdc87abd480a136c090cc345 to your computer and use it in GitHub Desktop.
Fix Wordpress emails disappearing due to incorrect return-path set from phpmailer
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
<?php | |
/* | |
Plugin Name: Email Return Path Fix | |
Author: Abdussamad Abdurrazzaq | |
*/ | |
class email_return_path { | |
function __construct() { | |
add_action( 'phpmailer_init', array( $this, 'fix' ) ); | |
} | |
function fix( $phpmailer ) { | |
$phpmailer->Sender = $phpmailer->From; | |
} | |
} | |
new email_return_path(); | |
?> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment