📄 newmail.asp
字号:
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title>使用NewMail 发送邮件</title>
</head>
<body>
<h1 align="center">使用NewMail 发送邮件</h1>
<center>
<form action="" name="form1" method="post">
请输入您的注册邮箱:<input type="text" size="20" name="tomail"><br><br>
<input type="submit" value=" 提 交 ">
</form>
<%
'判断是否提交
if Request.ServerVariables("Request_Method")="POST" then
'是提交
Set myMail = Server.CreateObject("CDONTS.NewMail")
HTML = "<font color=red>您的新口令为:123456</font>"
'发件人
myMail.From = "xx@xx.com"
'收件人
myMail.To = request("tomail")
'邮件的重要性 0 重要性低 , 1 重要性一般(默认), 2 重要性高
myMail.Importance = 2
'邮件主题
myMail.Subject = "XX网上的新密码"
'给邮件对象的文本赋值
myMail.Body = HTML
'将邮件发出
myMail.Send
'销毁对象实例,释放内存
Set myMail = Nothing
response.Write "已将新口令发送到注册邮箱,请查收"
end if
%>
</center>
</body>
</html>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -