Jump to content

html charset email


DrTrans

Recommended Posts

Why do the html tags show threw when it sends the mail. I have the charset set.

 

  $person = $_POST['email'];
  $submit = $_POST['submit'];
  
  
  if($submit) {
  //// EMAIL SCRIPT
ini_set("sendmail_from", "$dbusername <$dbusername>");
$message = "
<html>
<p><strong>$dbusername</strong> has sent you a request for Site!</p>

<p> Please follow the hyperlink below to fill out your new rental home application. </p>
<br />
<a href=\"https://site/application.php?ownerid=$loginid&process=1\">Click Here for Application!</a>
<br>
</html>
";


    $mailsubject = "Application Request from Site!";
    $headers  = "From: Site! <$dbusername>\r\n";
    $headers .= 'MIME-Version: 1.0' . "\n";
    $headers .= 'Content-type: text/html; charset=utf-8' . "\r\n";   
        $sendmail = mail($person,$mailsubject,$message,$headers);

//echo "<BR/>mail() returned: " . ($sendmail? "TRUE" : "FALSE") . "<BR/>";
//	echo "$property -- $service --- $extra -- $pay --$mainemail";
    printf("<script>location.href='dashboard.php?control=managea'</script>");
}  


Link to comment
https://forums.phpfreaks.com/topic/267374-html-charset-email/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.