?? admin_mailist.asp
字號:
<!--#include file=conn.asp-->
<!-- #include file="inc/const.asp" -->
<!--#include file=inc/email.asp-->
<title><%=txl_info(0)%>--管理頁面</title>
<!--#include file="inc/admin_css.asp"-->
<meta NAME=GENERATOR Content="Microsoft FrontPage 3.0" CHARSET=GB2312>
<BODY leftmargin="0" bottommargin="0" rightmargin="0" topmargin="0" marginheight="0" marginwidth="0" bgcolor="#DDEEFF">
<%
if not supermaster or session("flag")="" then
Errmsg=Errmsg+"<br>"+"<li>本頁面為管理員專用,請<a href=admin_index.asp target=_top>登陸</a>后進(jìn)入。<br><li>您沒有管理本頁面的權(quán)限。"
call txl_error()
else
dim topic,mailbody
i=1
set rs= server.createobject ("adodb.recordset")
if request("action")="send" then
call sendmail()
else
call mail()
end if
end if
sub mail()
%>
<form action="admin_mailist.asp?action=send" method=post>
<table cellpadding="2" cellspacing="1" border="0" width="95%" class="tableBorder" align=center>
<tr>
<th colspan="2">同學(xué)錄郵件列表
</th>
</tr>
<tr>
<td width="20%" class=txlrow>注意事項:</td>
<td class=txlrow>在完整填寫以下表單后點擊發(fā)送,信息將發(fā)送到所有注冊時完整填寫了信箱的用戶,郵件列表的使用將消耗大量的服務(wù)器資源,請慎重使用。</td>
</tr>
<tr>
<td width="20%" class=txlrow>郵件標(biāo)題:</td>
<td class=txlrow><input type=text name=topic size=60></td>
</tr>
<tr>
<td width="20%" class=txlrow>郵件內(nèi)容:</td>
<td class=txlrow><textarea cols=80 rows=6 name="content"></textarea></td>
</tr>
<tr> <td width="20%" class=txlrow></td>
<td height=20 class=txlrow>
<input type=Submit value="發(fā) 送" name=Submit"> <input type="reset" name="Clear" value="清 除">
</td>
</tr>
</table>
</form>
<%
end sub
sub sendmail()
if request("topic")="" then
Errmsg=Errmsg+"<br>"+"<li>請輸入郵件標(biāo)題。"
founderr=true
else
topic=request("topic")
end if
if request("content")="" then
Errmsg=Errmsg+"<br>"+"<li>請輸入郵件內(nèi)容。"
founderr=true
else
mailbody=request("content")
end if
if founderr=false then
on error resume next
sql="select realname,email from [user]"
rs.open sql,conn,1,1
if not rs.eof and not rs.bof then
alluser=rs.recordcount
do while not rs.eof
if rs("email")<>"" then
useremail=rs("email")
if txl_set(4)=0 then
errmsg=errmsg+"<br>"+"<li>本同學(xué)錄不支持發(fā)送郵件。"
exit sub
elseif txl_set(4)=1 then
call jmail(useremail,topic,mailbody)
elseif txl_set(4)=2 then
call Cdonts(useremail,topic,mailbody)
elseif txl_set(4)=3 then
call aspemail(useremail,topic,mailbody)
end if
i=i+1
end if
rs.movenext
loop
Errmsg=Errmsg+"<br>"+"<li>成功發(fā)送"&i&"封郵件。"
end if
rs.close
set rs=nothing
conn.close
set conn=nothing
end if
response.write ""&Errmsg&""
end sub
%>
?? 快捷鍵說明
復(fù)制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -