You can use the following method.
function sendMail($email, $subject, $message)
{
$supportEmail = 'info@abc.com';
$from = 'Abc';
$msg = $message;
$from = str_replace(' ', '-', $from);
$frm = $from.' <'.$supportEmail.'>';
preg_match("<(.*)@(.*\..*)>", $frm, $match);
///////////////////Headers/////////////////
$hdr='';
$hdr.='MIME-Version: 1.0'."\n";
$hdr.='content-type: text/html; charset=iso-8859-1'."\n";
$hdr.="From: {$frm}\n";
$hdr.="Reply-To: {$frm}\n";
$hdr.="Message-ID: <".time()."@{$match[2]}>\n";
$hdr.='X-Mailer: PHP v'.phpversion();
$x=@mail($email, $subject, $msg, $hdr);
if($x==0)
{
$email=str_replace('@','\@', $email);
$hdr=str_replace('@','\@',$hdr);
$x=@mail($email, $subject, $msg, $hdr);
}
return $x;
}