📄 adminemail.asp
字号:
<!--#include file="Connections.asp" -->
<!--#include file="adminaccess.asp" -->
<body <%=background%> >
<% dim h_selectemail,h_emailserver
sql="select h_selectemail,h_emailserver from home"
set rsconn1=conn.execute(sql)
if not rsconn1.eof then
h_emailserver=trim(rsconn1("h_emailserver"))'email邮件地址
h_selectemail=rsconn1("h_selectemail")'开通emial
end if
set rsconn1=nothing
if Request.QueryString("action")="do" then
q_title=chktopic(request.form("q_title"))
q_content=chktopic(request.form("q_content"))
if q_title="" then
errornum=1
errormsg=errormsg&"<li>标题不能为空</li>"
end if
if q_content="" then
errornum=1
errormsg=errormsg&"<li>内容不能为空</li>"
end if
if errornum=1 then
call error(errormsg)
response.end
end if
emailtopic=q_title
emailbody=""&vbCrlf&"亲爱的"&q_username&", 您好!"
emailbody=emailbody & ""&vbCrlf&""&vbCrlf&"这是"&l_title&"发送给您的邮件!内容如下:"&vbCrlf&""
emailbody=emailbody & q_content
emailbody=emailbody &""&vbCrlf&"本论坛地址:"&l_urlf
emailbody=emailbody & ""&vbCrlf&""&vbCrlf&"dxxo论坛制作(http://down.dxxo.com)"&vbCrlf&"程序制作:down.dxxo.com(飞越)"&vbCrlf&""&vbCrlf&""
sql6="select email from user"
set rs6=conn.execute(sql6)
if not (rs6.eof or rs6.bof) then
do while not rs6.eof
if rs6("email")<>"" then
i=0
emaito=rs6("email")%>
<!-- #include file="email.asp" -->
<%
end if
rs6.movenext
i=i+1
loop
end if
if SendMail="OK" then
sendmsg="邮件发送成功,共发送"&i&"封邮件<br>"
else
sendmsg=sendmsg&"很抱歉,由于系统错误,发送失败<br>"
end if
response.write("<div class=tdc>"&sendmsg&"</div>")
response.end
end if
%>
<% if Request.QueryString("action")="do1" then
q_title=chktopic(request.form("q_title"))
q_content=chktopic(request.form("q_content"))
emailto=chktopic(request.form("q_email"))
q_username=chktopic(request.form("q_username"))
if q_username="" then
errornum=1
errormsg=errormsg&"<li>接收人不能为空</li>"
end if
if emailto="" then
errornum=1
errormsg=errormsg&"<li>email不能为空</li>"
end if
email1=Split(emailto, "@")
if UBound(email1) <>1 then
errornum=1
errormsg=errormsg&"<li>email格式不对</li>"
else
email1=Split(emailto, ".")
if UBound(email1) <1 then
errornum=1
errormsg=errormsg&"<li>email格式不对</li>"
end if
end if
if q_title="" then
errornum=1
errormsg=errormsg&"<li>标题不能为空</li>"
end if
if q_content="" then
errornum=1
errormsg=errormsg&"<li>内容不能为空</li>"
end if
if errornum=1 then
call error(errormsg)
response.end
end if
emailtopic=q_title
emailbody=""&vbCrlf&"亲爱的"&q_username&", 您好!"
emailbody=emailbody & ""&vbCrlf&""&vbCrlf&"这是"&l_title&"发送给您的邮件!内容如下:"&vbCrlf&""
emailbody=emailbody & q_content
emailbody=emailbody &""&vbCrlf&"本论坛地址:"&l_urlf
emailbody=emailbody & ""&vbCrlf&""&vbCrlf&"dxxo论坛制作(http://down.dxxo.com)"&vbCrlf&"程序制作:down.dxxo.com(飞越)"&vbCrlf&""&vbCrlf&""
%>
<!-- #include file="email.asp" -->
<%
if SendMail="OK" then
sendmsg="邮件发送成功<br>"
else
sendmsg=sendmsg&"很抱歉,由于系统错误,发送失败<br>"
end if
response.write("<div class=tdc>"&sendmsg&"</div>")
response.end
end if
%>
<table border=1 borderColor=<%=tdc2%> cellPadding=3 cellSpacing=1 width=100% style="border-collapse: collapse" align=center >
<form name="form1" method="POST" action="?action=do" >
<tr align="center">
<td colspan="2" <%=tColor%> class=tdc1 height=22>论坛邮件列表</td>
</tr>
<tr>
<td align="right" width="20%" bgcolor=<%=tColor2%> class=tdc>邮件主题:</td>
<td bgcolor=<%=tColor2%> class=tdc>
<input type="text" name="q_title" class=tdc size="30" >
</td>
</tr>
<tr>
<td align="right" width="20%" bgcolor=<%=tColor2%> class=tdc>邮件内容:</td>
<td bgcolor=<%=tColor2%> class=tdc>
<textarea rows="4" name="q_content" cols="50"></textarea>
</td>
</tr>
<tr>
<td width="20%" align="right" bgcolor=<%=tColor2%> class=tdc> </td>
<td bgcolor=<%=tColor2%> class=tdc>
<input type="submit" name="Submit" value="提交" class=bdtj>
<input type="reset" name="Submit2" value="重置" class=bdtj>
</td>
</tr>
<tr>
<td align="right" width="20%" bgcolor=<%=tColor2%> class=tdc colspan="2">
信息将发送到所有注册时完整填写了信箱的用户,邮件列表的使用将消耗大量的服务器资源,请慎用。
</td>
</tr>
</table>
</div>
</form>
<table border=1 borderColor=<%=tdc2%> cellPadding=3 cellSpacing=1 width=100% style="border-collapse: collapse" align=center >
<form name="form1" method="POST" action="?action=do1" >
<tr align="center">
<td colspan="2" <%=tColor%> class=tdc1 height=22>发送邮件</td>
</tr>
<tr>
<td align="right" width="20%" bgcolor=<%=tColor2%> class=tdc>接收人:</td>
<td bgcolor=<%=tColor2%> class=tdc>
<input type="text" name="q_username" class=tdc size="30" >
</td>
</tr>
<tr>
<td align="right" width="20%" bgcolor=<%=tColor2%> class=tdc>接收人email:</td>
<td bgcolor=<%=tColor2%> class=tdc>
<input type="text" name="q_email" class=tdc size="30" >
</td>
</tr>
<tr>
<td align="right" width="20%" bgcolor=<%=tColor2%> class=tdc>邮件主题:</td>
<td bgcolor=<%=tColor2%> class=tdc>
<input type="text" name="q_title" class=tdc size="30" >
</td>
</tr>
<tr>
<td align="right" width="20%" bgcolor=<%=tColor2%> class=tdc>邮件内容:</td>
<td bgcolor=<%=tColor2%> class=tdc>
<textarea rows="4" name="q_content" cols="50"></textarea>
</td>
</tr>
<tr>
<td width="20%" align="right" bgcolor=<%=tColor2%> class=tdc> </td>
<td bgcolor=<%=tColor2%> class=tdc>
<input type="submit" name="Submit" value="提交" class=bdtj>
<input type="reset" name="Submit2" value="重置" class=bdtj>
</td>
</tr>
<tr>
<td align="right" width="20%" bgcolor=<%=tColor2%> class=tdc colspan="2">
<p align="center">信息将发送到您想发送的邮箱</td></tr>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -