OpenCart - 中文论坛
标题:
opencart用SMTP发邮件邮件标题乱码问题
[打印本页]
作者:
sunboy
时间:
2015-3-11 10:59
标题:
opencart用SMTP发邮件邮件标题乱码问题
在客户端看到邮件如下所示:
QQ截图20150311092505.jpg
(73.27 KB, 下载次数: 22)
下载附件
保存到相册
2015-3-11 09:25 上传
订单邮件:
文件路径: /catalog/model/checkout/order.php
找了OC的代码并注释:
//$mail->setSubject(html_entity_decode($subject, ENT_QUOTES, 'UTF-8'));
添加如下代码:
$subject = "=?UTF-8?B?".base64_encode($subject)."?=";
$mail->setSubject($subject);
注册邮件:
文件路径: /catalog/model/account/customer.php
找了OC的代码并注释:
//$mail->setSubject(html_entity_decode($subject, ENT_QUOTES, 'UTF-8'));
添加如下代码:
$subject = "=?UTF-8?B?".base64_encode($subject)."?=";
$mail->setSubject($subject);
忘记密码邮件: /catalog/controller/account/forgotten.php
找了OC的代码并注释:
//$mail->setSubject(html_entity_decode($subject, ENT_QUOTES, 'UTF-8'));
添加如下代码:
$subject = "=?UTF-8?B?".base64_encode($subject)."?=";
$mail->setSubject($subject);
注意如果使用mail协议发送时不需要修改上面的代码
欢迎光临 OpenCart - 中文论坛 (https://bbs.opencart.cn/)
Powered by Discuz! X3.2