原本utf8编码需要转换成iso-2022-jp
日本手机大部分不能识别utf8,只能识别iso-2022-jp
$subject = (stristr($email, '.com')) ? $title : '=?iso-2022-jp?b?' . base64_encode(iconv('utf-8', 'iso-2022-jp', $title)) . '?=';
$message = (stristr($email, '.com')) ? $body : iconv('utf-8', 'iso-2022-jp', $body);
$headers = 'MIME-Version: 1.0' . "\r\n";
$headers .= 'Content-type: text/html; charset=iso-2022-jp' . "\r\n";
// Additional headers
//$headers .= 'To: ' . $to . "\r\n";
$from = 'xxxx@bluhbluh.mobi';
$headers .= 'From: ' . $from . "\r\n";
$headers .= 'CC: ' . $cc . "\r\n";
mail($email, $subject, $message, $header);
?>
没有评论:
发表评论