Trying to send a MIME e-mail in both plain text and html (per client request). If I just send with Content-Type: text/html, it will definitely show in e-mail viewer. The problem is when I try to do the multipart/alternative content-type, I get a blank e-mail in Hotmail and Yahoo. Code below. Any help would be greatly appreciated.
// E-mail Body Message
$mime_boundary="==Multipart_Boundary_x".md5(mt_rand())."x";
$message = "Content-Transfer-Encoding: 7bit\n" . "This is a multi-part message in MIME format. This part of the E-mail should never be seen. If you are reading this, consider upgrading your e-mail client to a MIME-compatible client.\n\n" . "--{$mime_boundary}\n" .
"Content-Type: text/plain; charset=iso-8859-1\n" . "Content-Transfer-Encoding: 7bit\n\n" .
"This is the text portion of an HTML e-mail.\n" . "--{$mime_boundary}\n" .
"Content-Type: text/html; charset=iso-8859-1\n" . "Content-Transfer-Encoding: 7bit\n\n" .
"<html><body><p>Sent By: ". $name . "<br /><br />" . "Sender's E-mail Address: ". $sentby . "<br /><br />" . "Personal Message: " . $comment . "<br /><br />" . "URL: <a href='" . $url . "'>" . $url . "</a></p>" . $PHPrint . "</body></html>" . "--{$mime_boundary}--";
$headers = "From: " . $from . "\n";
$headers.= "Reply-To: " . $sentby . "\n";
$headers.= "MIME-Version: 1.0\n" . "Content-Type: multipart/alternative;\n" . " boundary=\"{$mime_boundary}\n\"";
mail($email, $subject, $message, $headers);
echo "<h1>The WorkKeys<sup>®</sup> Charts were successfully submitted.</h1><br>
<p class='datainf'>Return to SchoolData4all's <a href='http://".$refpage."'>WorkKeys<sup>®</sup> Overall</a> Chart</p>";}