I'm having an issue with sending HTML Emails. Here is my code, but nothing comes out right when it gets emailed. And my email client is set to view HTML. I can view other HTML emails just fine, but not these.
Here is my code to send the email, just wondering whats wrong with it. Thanks for any suggestions.
$full_email = $frm_to . '@scotthermanfitness.com';
//define the receiver of the email
$to = $full_email;
//define the subject of the email
$subject = 'Form Submit - SHF ' . $to_text . ' (' . $frm_name . ')';
//create a boundary string. It must be unique
//so we use the MD5 algorithm to generate a random hash
$random_hash = md5(date('r', time()));
//define the headers we want passed. Note that they are separated with \r\n
$headers = "From: " . $frm_email . "\r\nReply-To: " . $frm_email;
//add boundary string and mime type specification
//$headers .= "\r\nContent-Type: multipart/alternative; boundary=\"PHP-alt-".$random_hash."\"";
$headers .= " Content-type: text/html\r\n";
//begin of HTML message
$message = $frm_content;
//send the email
$mail_sent = @mail( $to, $subject, $message, $headers );