headers for html email php
What is the minimum amount of headers you need to add to a html e-mail. Also, please tell which ones I'开发者_Go百科ll need to add or remove. I got
$HEADERS = 'MIME-Version: 1.0' . "\r\n";
$HEADERS .= 'Content-type: text/html; charset=UTF-8' . "\r\n";
also, is there any other way to right this better?
thanks
Take a look at PHPMailer or SwiftMailer, which provide a nice, easy and flexible API for sending emails from PHP. They give you additional functionality such as adding attachments to emails or connecting to another SMTP server and also provide a safer way of sending out emails from user supplied data.
精彩评论