Private Sub Command1_Click()
Dim msg As New jmail.Message
msg.Silent = True
msg.Logging = True
msg.MailServerUserName = "saikoyz" '输入smtp服务器验证登陆名
msg.MailServerPassWord = "1111111" ' 输入smtp服务器验证密码
msg.From = "[email protected]" '发件人
msg.FromName = "web"
msg.AddRecipient "[email protected]" ', "...@..." '收件人msg.Subject = "主题"
msg.Body = "正文"
MsgBox msg.Send("smtp.sina.com.cn") 'smtp服务器地址Set msg = Nothing
End Sub
代码如上,而且msgbox 出的消息为 true ,可打开油箱就是没收到邮件呀!!!为什么呢????
Dim msg As New jmail.Message
msg.Silent = True
msg.Logging = True
msg.MailServerUserName = "saikoyz" '输入smtp服务器验证登陆名
msg.MailServerPassWord = "1111111" ' 输入smtp服务器验证密码
msg.From = "[email protected]" '发件人
msg.FromName = "web"
msg.AddRecipient "[email protected]" ', "...@..." '收件人msg.Subject = "主题"
msg.Body = "正文"
MsgBox msg.Send("smtp.sina.com.cn") 'smtp服务器地址Set msg = Nothing
End Sub
代码如上,而且msgbox 出的消息为 true ,可打开油箱就是没收到邮件呀!!!为什么呢????
Set JMail=Server.CreateObject("JMail.Message")
if err<>0 then
response.write "服务器没有安装jmail组件!!!"
response.end
end if
str="你在电子商店网站对"&product_name&"进行询价,价格为:"&price&"。"
JMail.ContentType="text/html"
JMail.Encoding = "base64"
JMail.Charset="gb2312"
' 身份验证,如果发送不成功,请加上身份验证信息
JMail.MailServerUserName = "帐号" ' 身份验证的用户名
JMail.MailServerPassword = "密码" ' 身份验证的密码
JMail.from = "[email protected]"'写上发送邮箱
JMail.Subject = "电子商店给你发的询价结果"
JMail.AddRecipient(email)
JMail.Body =str
JMail.AddHeader "Originating-IP", Request.ServerVariables("REMOTE_ADDR")
JMail.Send("smtp.163.net")
JMail.Close
Set JMail = Nothing
'--------------------------------------------------
你直接用上面的代码吧,我都是用它发的。