当前位置:编程学习 > php >>

使用php的编码功能-实例调用(3)

<?php
include_once("mime.inc");
$mm = new MIME();
$to = "customer@263.net";
$subject = $mm->encode("商城","gb2312"); // 编码
$msg = "注册会员成功<br>";
$msg .= "会员名:wayne<br>";
$msg .= "密码:wayne</font>";
$headers = "From: webmaster@263.net Content-Type: text/html; charset=gb2312 ";
mail("$to", "$subject", "$msg", "$headers");    
?>
进行编码以后,中文问题解决。
补充:Php教程,邮件处理
CopyRight © 2022 站长资源库 编程知识问答 zzzyk.com All Rights Reserved
部分文章来自网络,