- $to = 'phplovers@example.com';
- $subject = "=?UTF-8?B?".base64_encode('邮件标题')."?=";
- $headers = 'MIME-Version: 1.0' . "\\r\\n";
- $headers .= 'Content-type: text/html; charset=utf-8' . "\\r\\n";
- // Additional headers
- $headers .= 'To: Xinple <'">'phplovers@example.com>' . "\\r\\n";
- $headers .= 'From: Admin <'">admin@example.com>' . "\\r\\n";
- $headers .= 'Reply-To: Xinple <'">'phplovers@example>' . "\\r\\n";
- mail($to, $subject, $message, $headers);
- //该片段来自于http://www.codesnippet.cn/detail/03122012762.html
来源: http://www.codesnippet.cn/detail/03122012762.html