Problems with wp_mail
-
Howdy, y’all!
I’m trying to use wp_mail to send emails out through an office 365 relay. I was told that the relay is configured to only accept traffic from the server I am working from, port 25 and requires no login and pass, and I am able to telnet to the server and send mail on port 25 without authenticating, so that part seems good, but I cannot send mail using wp_mail. It simply throws an error “SMTP Error: Could not connect to SMTP host.”I have my phpmailer config set thusly:
add_action( ‘phpmailer_init’, ‘o365_init’ );
function o365_init( $phpmailer ) {
$phpmailer->isSMTP();
$phpmailer->Host = ‘myrelayhostname’;
$phpmailer->SMTPAuth = false;
$phpmailer->Port = 25;
$phpmailer->SMTPDebug = false;
}What am I doing wrong? Is there any way I can squeeze any more info out of this other than “Duh, can’t connect to host, boss!”
- The topic ‘Problems with wp_mail’ is closed to new replies.