国产探花免费观看_亚洲丰满少妇自慰呻吟_97日韩有码在线_资源在线日韩欧美_一区二区精品毛片,辰东完美世界有声小说,欢乐颂第一季,yy玄幻小说排行榜完本

首頁 > 學院 > 開發設計 > 正文

用EasyMailObject組件處理Exchange郵件源代碼(5)

2019-11-18 20:20:27
字體:
來源:轉載
供稿:網友
asp中用EasyMailObject組件處理Exchange郵件源代碼---發送郵件(p_sendmail.asp)

<%@ Language=VBScript %>
<%
'*************************************

'這個文件用來發送郵件
'作者:awayeah
'郵箱:awayeah@163.net

'*************************************

if session("straccount")="" or session("strpassWord")="" then
Response.End
end if
%>
<HTML>
<HEAD>
<META NAME="GENERATOR" Content="Microsoft Visual Studio 6.0">
</HEAD>
<STYLE>
<!--
A{text-decoration:none}
-->
</STYLE>
<BODY>
<%   Set SMTP = CreateObject("EasyMail.SMTP.5")
   SMTP.LicenseKey = "awa/S19I500R1AX30C0R3100"
   SMTP.MailServer = "192.9.200.89"
   SMTP.Subject = Request.Form("subject")
   SMTP.BodyText = Request.Form("bodytext")
   SMTP.From = Request.Form("from")
   SMTP.FromAddr = Request.Form("fromaddr")
   SMTP.AddRecipient Request.Form("from"), Request.Form("receive1") , 1
   
   '添加附件
   if Request.Form("att")="" then
   Response.Write ""
   else
   x = SMTP.AddAttachment(Request.Form("att"), 0)
   If Not x = 0 Then
     Response.Write "插入附件錯誤: " + cstr(x) + "請與管理員聯系。"
   End If
   end if
   x = SMTP.Send

   If x = 0 Then
'      Response.Write ("<P align=center><br><br>")
'     Response.Write ("<font size=")
      Response.Write "<p align='center'><br><br><b><font face='宋體' size='5' color='#00FFFF'><span style='background-color: #000080'>郵件已成功發出!</font></span></b>"
'      session("sended")="Y"
   Else
  if x=7 or x=5 then
      Response.Write "<br><br><p align='center'><b><font face='宋體' size='5' color='#00FFFF'><span style='background-color: #000080'>發郵件發生錯誤(" + cstr(x)+ ").發件人地址錯誤</span></font></b>"%>
       <br><br><input type="button" onclick="history.go(-1)"  value="返回">
      <%Response.End
  else
      Response.Write "<br><br><p align='center'><b><font face='宋體' size='5' color='#00FFFF'><span style='background-color: #000080'>發郵件發生錯誤: "   + cstr(x)+ "</span></font></b>"%>
       <br><br><input type="button" onclick="history.go(-1)"  value="返回" id=button1 name=button1>
      <%Response.End
  end if
  End If


   Set SMTP = Nothing
   
%>

<P align="center"> <a href="javascript:window.close();">
<font face="宋體" size="5"><b><span style="background-color: #FFFF00">返回</span></b></font></a></P>

</BODY>
</HTML>


發表評論 共有條評論
用戶名: 密碼:
驗證碼: 匿名發表
主站蜘蛛池模板: 武胜县| 旌德县| 桐城市| 威信县| 隆子县| 区。| 安阳市| 若尔盖县| 荆州市| 涿州市| 迁安市| 格尔木市| 托克逊县| 梨树县| 通榆县| 金门县| 常熟市| 呼图壁县| 铜鼓县| 龙岩市| 定安县| 当涂县| 沁源县| 石泉县| 绵阳市| 稻城县| 甘孜县| 潞西市| 北碚区| 磐安县| 卓资县| 大厂| 德令哈市| 思茅市| 佳木斯市| 东阳市| 高邮市| 万安县| 兴宁市| 清水县| 新巴尔虎右旗|