我们目前正在将邮件递送系统更改为仅使用UTF-8
.
发件人姓名似乎有问题,当电子邮件包含非 ASCII 字符(希伯来语)时,主题和正文呈现正常,但发件人姓名(如出现在我的 gmail 帐户中)变为 -??????
.
有一行代码:
myMail.BodyPart.Charset = "UTF-8"
所以我想应该有一些类似的代码:
myMail.SenderName.Charset = "UTF-8"
但我似乎无法找到正确的代码来使用,假设这可以解决问题。
这对我有用:http://www.powerasp.net/content/new/sending_email_cdosys.asp http://www.powerasp.net/content/new/sending_email_cdosys.asp
Dim ObjSendMail
Set ObjSendMail = CreateObject("CDO.Message")
ObjSendMail.Configuration.Fields.Item ("http://schemas.microsoft.com/cdo/configuration/sendusing") = 2
ObjSendMail.Configuration.Fields.Item ("http://schemas.microsoft.com/cdo/configuration/smtpserver") = "myserver"
ObjSendMail.Configuration.Fields.Item ("http://schemas.microsoft.com/cdo/configuration/smtpserverport") = 25
ObjSendMail.Configuration.Fields.Item ("http://schemas.microsoft.com/cdo/configuration/smtpusessl") = False
ObjSendMail.Configuration.Fields.Item ("http://schemas.microsoft.com/cdo/configuration/smtpconnectiontimeout") = 60
ObjSendMail.Configuration.Fields.Update
ObjSendMail.To = to_email
ObjSendMail.Subject = subject
ObjSendMail.From = from_email
'ObjSendMail.TextBody = mensaje 'tipo texto
ObjSendMail.HTMLBody = mensaje 'tipo html
ObjSendMail.TextBodyPart.Charset = "utf-8" 'support symbols á ñ ¡
ObjSendMail.Send
Set ObjSendMail = Nothing
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)