zoukankan      html  css  js  c++  java
  • jmail asp 发送邮件 绝对好用

    'sendMail"99669806@qq.com","QQ","aaaa","bb"

    '收件人邮箱,发件人姓名,标题,内容

    Function sendMail(email,sendname,zhuti,mailbody)

    Server.ScriptTimeOut=5000

    If Not isInstallObj("JMail.Message") Then exit function

    dim jmail : set jmail=Server.CreateObject("JMail.Message")

    If jmail is nothing then exit function

    set jmail= server.CreateObject ("Jmail.message") '调用Jmail组件

    jmail.Silent = true

    jmail.Charset = "utf-8"

    JMail.ContentType = "text/html"

    '调用变量内容

    '=================================

    '发件人邮箱

    jmail.From = smtp_usermail

    '发件人姓名

    jmail.FromName = sendname

    '收件人邮箱

    jmail.ReplyTo = email

    '邮件标题

    jmail.Subject = zhuti

    dim aryEmail,i

    if Instr(email,",")>0 then

    aryEmail = split(email, ",")

    for i=0 to UBound(aryEmail)

    if aryEmail(i)<>"" then JMail.AddRecipient Trim(aryEmail(i))''收件人郵箱地址,收件人姓名

    next

    else

    '收件人邮箱

    jmail.AddRecipient email

    End if

    '邮件内容

    jmail.Body = mailbody

    '用户名

    jmail.MailServerUserName = smtp_user

    '密码

    jmail.MailServerPassWord = smtp_password

    '发送邮件

    sendMail=jmail.Send(smtp_server)

    jmail.close : set jmail = nothing

    End Function

  • 相关阅读:
    webstock学习
    H5存储
    js保留两位小数
    html5拖动滑块
    js判断网页访问设备类型
    关于hadoop setCombinerClass 与 setReducerClass同时使用存在的问题。
    hadoop 输出中文乱码问题
    mapreduce实现学生平均成绩
    mapreduce 实现数子排序
    hadoop mapreduce实现数据去重
  • 原文地址:https://www.cnblogs.com/exit/p/2861365.html
Copyright © 2011-2022 走看看