Possible Duplicate:
Sending HTML email from PHP
Using PHP to send an email.
I want it to be HTML based but when I get the email in my inbox it just shows the raw code.
How can I make it interprited as HTML rather then just text?!
For everyone asking to see the code
<?php
//The email of the sender
$email = $_POST['email'];
//The message of the sender
$message = "<html></html>";
//The subject of the email
$subject = "Fanshawe Student Success";
$extra = $email."\r\nReply-To: ".$email."\r\n";
mail($email,$subject,$message,$extra);
?>
from the docs: http://php.net/manual/en/function.mail.php
$headers .= 'Content-type: text/html; charset=iso-8859-1' . "\r\n";
obviously $headers has to be passed to the mail
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With