I have a domain www.ipsmeerut.com
, i m using the script below to send mail. It is returning true but mail is not sending.
Here's my script:
<?php
$to = 'brajnacs@gmail.com';
$subject = 'Test';
$headers = "From: Test<no-reply@ipsmeerut.com>
";
$headers .= "MIME-Version: 1.0
";
$headers .= "Content-Type: text/html; charset=ISO-8859-1
";
$message = "<html><body>";
$message .= "<h1>Hello, World!</h1>";
$message .= "</body></html>";
$res=false;
$res=mail($to, $subject, $message, $headers);
var_dump($res);
echo "Mail sent to ".$to;
?>
This script is working fine on my other domains. var_dump
is showing true
. My mail server is aspmx.l.google.com
and I have also added MX Entry
for it.