分类分类
2015-06-28 00:00作者:网管联盟
其实最关键的就是这句要注释掉
JMail.ContentType = text/html
(为什么要发内嵌的附件图片?因为如果是img src=/uploads/allimg/080527/2317420.jpg))
增加一个嵌入式附件
The return value of AddAttachment is used as a
reference to the image in the HTMLBody.
contentId = JMail.AddAttachment(Server.MapPath(images/email.gif))
Dim contentId
contentId = JMail.AddAttachment(E:imagesemail.gif)
只有HTML格式支持嵌入图片附件,我们采用HTML格式的邮件内容
As only HTML formatted emails can contain inline images
we use HTMLBody and appendHTML
JMail.HTMLBody = <html><body><font color=red>Hi, here is a nice picture:</font><br>
JMail.appendHTML <img src=cid: & contentId & >
JMail.appendHTML <br><br> good one huh?</body></html>
如果对方信箱不支持HTML格式邮件,我们仍需要给他一个友善的提示
But as not all mailreaders are capable of showing HTML emails
we will also add a standard text body
JMail.Body = Too bad you cant read HTML-mail.
JMail.appendText There would have been a nice picture for you
JMail.Send( mail.skyhe.com )
JMail.Close()
Set JMail = Nothing
%>
相关文章