Click to See Complete Forum and Search --> : html e-mail issue


pulleys
10-09-2007, 04:50 PM
hi,

I have a php script that generates an html e-mail but when it e-mails the e-mail shows up just as unprocessed html. It seems like the e-mail program is not rendering the html at all. It does this with both gmail and Mac Mail. I've been online looking for a solution online but end up going in circles. I have a feeling it's something to do with the headers.

Heres the relevant code:


$headers .= "MIME-version: 1.0\r\n";
$headers .= "Content-type: text/html\r\n";
$headers .= "From: $fromName ($fromEmail)";


mail($toEmail, $subject, $message_html ,$headers);




Any ideas.

Thanks

Fang
10-10-2007, 02:31 AM
From plain text to file attachments (http://www.sitepoint.com/article/advanced-email-php)
HTML email guide (http://www.anandgraves.com/html-email-guide)