欢迎您光临用户专区!

如何用asp的jmail发邮件?

来源:新数据发布时间:2013-5-26 23:17:57
<%
Set msg = Server.CreateObject("JMail.Message")
msg.silent = true
msg.Logging = true
msg.Charset = "gb2312"
msg.MailServerUserName = "user@yourdomain.com" '输入smtp服务器验证登陆名 (邮局中任何一个用户的Email地址)
msg.MailServerPassword = "userpasswd" '输入smtp服务器验证密码 (用户Email帐号对应的密码)
msg.From = Request.Form("email") '发件人Email
msg.FromName = Request.Form("name") '发件人姓名
msg.AddRecipient "webmaster@abc.com" '收件人Email
msg.Subject = Request.Form("subject") '信件主题
msg.Body = Request.Form("body") '正文
msg.Send ("mail.yourdomain.com") 'smtp服务器地址(企业邮局地址)
set msg = nothing
%>