I have this function in my code which I will use to send all the mail on my site in HTML format:
function sendEmail($to,$subject,$message,$from,$fromAddress) {
$headers = "MIME-Version: 1.0\r\n";
$headers .= "Content-Type: text/html; charset=iso-8859-1\r\n";
$headers .= "Content-Transfer-Encoding: 7bit\r\n";
$headers .= "From: ".$from."<".$fromAddress.">\r\n";
$headers .= "Reply-To: ".$fromAddress."\r\n";
$headers .= "X-Mailer: PHP/".phpversion();
$message = stripslashes($message);
mail($to,$subject,$message,$headers);
}
Problems are, the HTML doesn't render in Microsoft Outlook but it does in Hotmail, the 'From' header does not appear in the From column in the eMail client and all the headers appear at the top of the eMail.
Any ideas or suggestion would be appreciated as I am getting confused.
Tony.