I have a PHP script that receives some incoming POST data to build a message. The message is sending, but not in HTML format. I receive the HTML code as text in the message, rather than an HTML-encoded mail message. I got most of this code from php.net, is there something I'm not doing quite right?
$msg='<html><head><title>Liever, Hyman & Potter</head></html><body>' . $_POST['msg'] . '</body></html>';
$headers='MIME-Version: 1.0' . '\r\n' . 'Content-type: text/html; charset=iso-8859-1' . '\r\n' . 'From:' . $_POST['sender'];
mail($recipient, $subject, $msg, $sender);
echo 'Mail Sent.';