clem_c_rock Posted November 13, 2008 Share Posted November 13, 2008 Hello, I have a script that suddenly stopped working and nothing's been changed. I am using the php mail() function to send a simple email form and the mail() function report true when it is fired off but I can never receive the emails. I suspect something's changed in our hosting but wanted to rule everything out before I started investigating there. Here's the simple code I am using: $send_tenant_mail = mail( $tenant_email, $subject, $body_header, "From: $from\nReply-To: $from\n" ); if($send_tenant_mail == 1) { $confirm = "A Confirmation Email has been sent to: $tenant_email"; } Thanks, Clem C Link to comment https://forums.phpfreaks.com/topic/132615-php-mail-function-reporting-mail-sent-but-mail-never-received/ Share on other sites More sharing options...
revraz Posted November 13, 2008 Share Posted November 13, 2008 You need to check your server log. The syntax is right, but the mail server may be denying it since the From is not from your domain. It's also possible the ISP you are sending it to is flagging it as spam. Link to comment https://forums.phpfreaks.com/topic/132615-php-mail-function-reporting-mail-sent-but-mail-never-received/#findComment-689566 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.