你可以通过SMTP服务或者MS Exchange发送HTML格式的邮件,但是,你需要注意的是,并不是所有的clients都可以正常显示。在通常的情况下,CDONTS发送邮件是使用plain-text格式。在使用HTML方式的时候我们可以进行更多的设置,例如不同的字体,颜色,插入图片等等。下面是一个例子
<%
Dim objMail
Set objMail = Server.CreateObject(“CDONTS.NewMail”)
//these are all the images that are in this message.
//you must include them like this.
//please note that you DO NOT have TO write the
//entire file path in the tag in the body after this.
//make sure you see the image name after the path separated by a comma
objMail.AttachURL “D:imagesmyImage.gif”, “myImage.gif”
objMail.AttachURL “D:imagesmyImage2.gif”, “myImage2.gif”
HTML = HTML %26amp; ““
HTML = HTML %26amp; ““
HTML = HTML %26amp; “
HTML = HTML %26amp; ““
HTML = HTML %26amp; ““
HTML = HTML %26amp; ““
HTML = HTML %26amp; “ ” “
HTML = HTML %26amp; now() %26amp; ” – “
HTML = HTML %26amp; “These are all great ASP Sites
HTML = HTML %26amp; ““
HTML = HTML %26amp; ““
HTML = HTML %26amp; “
“
HTML = HTML %26amp; ““
HTML = HTML %26amp; “
“
HTML = HTML %26amp; “
“
HTML = HTML %26amp; ““
HTML = HTML %26amp; ““
objMail.From = “rob@tconsult.com”
objMail.Subject = “Your daily HTML Mail”
you need TO add these lines FOR the mail
to be sent in HTML format
objMail.BodyFormat = 0
objMail.MailFormat = 0
objMail.To = “you@yourhouse.com
objMail.Body = HTML
objMail.Send
Response.write(“Mail was Sent”)
set objMail = nothing
%>
用html格式发送邮件_邮件服务器
版权申明:本站文章部分自网络,如有侵权,请联系:west999com@outlook.com 特别注意:本站所有转载文章言论不代表本站观点! 本站所提供的图片等素材,版权归原作者所有,如需使用,请与原作者联系。未经允许不得转载:IDC资讯中心 » 用html格式发送邮件_邮件服务器
相关推荐
-      MySQL常用的实用命令
-      mysql的root密码修改
-      Linux如何查看JDK的安装路径
-      Linux硬盘分区生效命令partprobe
-      Nginx下无法使用中文URL的解决方法
-      怎样dos命令(cmd命令)查看硬盘和内存/CPU信息
-      CentOS6下Apache开启Gzip网页压缩功能
-      Linux上查看用户创建日期的几种方法