mail(), html, & Outlook
Posted: Thu Mar 04, 2004 11:50 am
Well, I see that a while ago people had the same problems as me (http://www.phpbuilder.com/board/sho...readid=10240258), but I see no answers anywhere, so here goes:
I am sending E-Mail from a form on my website using the php mail(). The problem is that when I send it as html, outlook has problems. Here are the headers I'm using:
When I do this, the E-Mail looks fine in squirrelmail (a webmail program http://www.squirrelmail.org), but in outlook...instead of getting a nicely formatted html message, I get a message that starts with "Content-type: text/html;" then continues on in plaintext, showing me all the html tags, etc. I tried switching some of the headers around, and if I switch the mime & content-type headers, I see html in BOTH E-Mail programs, but outlook starts the message off with "MIME-Version: 1.0" which I suppose is the lesser of 2 evils, but there is no reason that I should have to see that. Does anyone have a solution?
I am sending E-Mail from a form on my website using the php mail(). The problem is that when I send it as html, outlook has problems. Here are the headers I'm using:
Code: Select all
$headers = "From: $name <$email>\r\n";
$headers .= "Reply-To: $email \r\n";
$headers .= "MIME-Version: 1.0\r\n";
$headers .= "Content-type: text/html;";