jimail发送错误,这是怎么回事 看看吧有源代码

zhy0771 2005-04-20 12:43:56
<html>
<head>
<title>发送表单</title>
<body>

<%
name = Request.Form ("name")
email= Request.Form ("email")
address= Request.Form ("address")
mailsubject= Request.Form ("mailsubject")
text1 = Request.Form ("text1")
text2 = Request.Form ("text2")
text3 = Request.Form ("text3")
%>

<%
' 创建jmail对象:
Set JMail = Server.CreateObject("JMail.SMTPMail")

' 设置发送邮件服务器(SMTP):
JMail.ServerAddress = "smtp.163.com"

' 发件人的信箱:
JMail.Sender = email

' 邮件标题:
JMail.Subject = mailsubject

' 设置邮件的收件人信箱(请使用在我司申请的邮箱):
JMail.AddRecipient "zhy0771@163.com"

' 下面就是填表在内容区填写的内容,&是连接符,vbcrlf表示换行回车:

mess = mess & "---------------Webmail表单开始-------------------" & vbcrlf
mess = mess & "留言人姓名:" & name & vbcrlf
mess = mess & "留言人邮件:" & email & vbcrlf
mess = mess & "留言人地址:" & address & vbcrlf
mess = mess & "留言内容一:" & text1 & vbcrlf
mess = mess & "留言内容二:" & text2 & vbcrlf
mess = mess & "留言内容三:" & text3 & vbcrlf
mess = mess & "---------------Webmail表单结束-------------------"
JMail.Body = mess

' 设置邮件的优先级(1-5,1为最高):
JMail.Priority = 1

' 执行发送任务:
JMail.Execute()
%>


您递交邮件已顺利发出,感谢您的意见和建议!
</body>
</html>

报错:
jmail.SMTPMail 错误 '8000ffff'

The message was undeliverable. All servers failed to receive the message

/send.asp,行48
...全文
79 3 打赏 收藏 转发到动态 举报
写回复
用AI写文章
3 条回复
切换为时间正序
请发表友善的回复…
发表回复
zhy0771 2005-04-20
  • 打赏
  • 举报
回复
isgo 是什么意思 有用吗
sosinoe 2005-04-20
  • 打赏
  • 举报
回复
if pEmailComponent="jmail" then

set mail = server.CreateOBject( "JMail.Message" )
mail.Logging = true
mail.silent = true
mail.From = from
mail.FromName = fromName
mail.Subject = subject

mail.AddRecipient rcpt

'mail.MailServerUserName = strUser
'mail.MailServerPassWord = strPassword

mail.Body = body

on error resume next

mail.send(pSmtpServer)

end if

if pEmailComponent="jmailhtml" then

set mail = server.CreateOBject( "JMail.Message" )
mail.Logging = true
mail.silent = true
mail.From = from
mail.FromName = fromName
mail.Subject = subject

mail.AddRecipient rcpt

' if the client cannot read HTML
mail.Body = body

' HTML
mail.HTMLBody = "<HTML><BODY><font color=""red"">" &pCompany& "</font><br>"
mail.appendHTML "<img src=""http://" & pStoreLocation & "/store/images/" &pCompanyLogo& """>"
mail.appendHTML "<br><br>" &body& "</BODY></HTML>"

on error resume next

mail.send(pSmtpServer)

end if
eafin 2005-04-20
  • 打赏
  • 举报
回复
你使用的jmail发送邮件程序太老了...下边这个,设置一下参数就可以使用
'---------发件代码----------'
'参数设置
Smtpserver = "" '发件服务器
Smtpuser = "" '发件用户名
Smtppwd = "" '发件密码
Smtpemail = "" '发件人email
FromEmail = "" '发件人email
FromNames = "" '发件人姓名
MailSubject = "" '邮件标题
ToName = "" '收件人email
Msg = "" '邮件内容
'发送邮件
Set Jmail= server.CreateObject ("Jmail.Message") '创建Jmail对象
Jmail.Silent = true
Jmail.Charset = "gb2312"
Jmail.ContentType = "text/html" '采用HTML形式发信
Jmail.From = FromEmail
Jmail.FromName = FromNames
Jmail.Subject = MailSubject
Jmail.AddRecipient ToName
Jmail.Body = Msg
Jmail.MailServerUserName = Smtpuser
Jmail.MailServerPassWord = Smtppwd
isgo = Jmail.Send(Smtpserver)
'关闭Jmail对象,释放资源
Jmail.Close
set Jmail = nothing
Response.Write("<center>邮件发送成功!</center>")

28,406

社区成员

发帖
与我相关
我的任务
社区描述
ASP即Active Server Pages,是Microsoft公司开发的服务器端脚本环境。
社区管理员
  • ASP
  • 无·法
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧