⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 sysadm_mailist.asp

📁 功能非常完整的校友录
💻 ASP
字号:
<!--#include file="conn.asp"-->
<!--#include file="const.asp" -->
<!--#include file=char.asp-->
<!--#include file=checkuser.asp-->
<!--#include file=email.asp-->
<title><%=SchoolmateName%>--管理页面</title>
<link rel="stylesheet" type="text/css" href="txl.css">

<body alink=#333333 vlink=#333333 link=#333333 topmargin=0 bgcolor=<%=bodycolor%>>
<%
	if  issystemadmin(0)=false or session("adminlogin")<>"OK" then
		Errmsg=Errmsg+"<br>"+"<li>本页面为管理员专用,请<a href=sysadm_index.asp target=_top>登陆</a>后进入。"
		call Error(errmsg)
	else
		call main()
		set rs=nothing
		conn.close
		set conn=nothing
	end if

	sub main()
%><BR>
<table cellpadding=0 cellspacing=0 border=0 width=<%=tablewidth%> bgcolor=<%=tablebordercolor%> align=center>
  <tr>
    <td>
      <table cellpadding=3 cellspacing=1 border=0 width=100%>
        <tr bgcolor='<%=Tabletitlecolor%>'>
        <td><font color="<%=TablefontColor%>">欢迎<b><%=membername%></b>进入管理页面</font>
        </td>
        </tr>
            <tr bgcolor=<%=tablebodycolor2%>>
              <td width="100%" valign=top><font color="<%=TableContentColor%>">
<%
if request("action")="send" then
call sendmail()
else
call mailform()
end if
%></font>
	      </td>
            </tr>
        </table>
        </td>
    </tr>
</table>
<%
end sub

sub mailform()
%>
<BR>
<form method="POST" action=sysadm_mailist.asp?action=send>
<table width="95%" border="0" cellspacing="1" cellpadding="3"  align=center bgcolor=<%=Tablebordercolor%>>
<tr bgcolor=<%=Tabletitlecolor%>> 
<td height="11" colspan="2" ><font color="<%=TableContentColor%>"><b>同学录邮件列表</b></font></td>
</tr>
<tr  bgcolor=<%=Tablebodycolor2%>> 
<td width="30%" height="18">&nbsp;&nbsp;<font color="<%=TableContentColor%>">邮件标题</font></td>
<td width="70%" height="18"> 
<input type="text" name="title" size="40" >
</td>
</tr>
<tr   bgcolor=<%=Tablebodycolor2%> >
<td width="30%" height="18">&nbsp;&nbsp;<font color="<%=TableContentColor%>">邮件内容</font></td>
<td width="70%" height="18"> 
        <textarea name="content" cols=40 rows=6></textarea>
</td></tr>

<tr   bgcolor=<%=Tablebodycolor2%> >
<td colspan=2 height="18"><font color="<%=TableContentColor%>"><b>说明:</b>注意:此项功能将信息发送到所有同学录的注册用户,当同学录中有大量的注册用户时,邮件列表的使用将消耗大量的服务器资源。 </font></td>
</tr>

<tr bgcolor=<%=Tabletitlecolor%>> 
<td height="23" colspan="2" align=right > 
<input type="submit" name="Submit" value="发 送">&nbsp;&nbsp;<input type="reset" name="reset" value="重 写">
</td>
</tr>
</table>
</form>
<%
end sub

sub sendmail()
	if request("title")="" then
		Errmsg=Errmsg+"<br>"+"<li>请输入邮件标题。"
		founderr=true
	else
		mailtopic=request("title")
	end if
	if request("content")="" then
		Errmsg=Errmsg+"<br>"+"<li>请输入邮件内容。"
		founderr=true
	else
		mailbody=request("content")
	end if

if founderr=true then 
	response.write Errmsg
	exit sub
end if


	mailfrom=systememail
	sql="select email from [student]"
	set rs=conn.execute(sql)
	if not rs.eof then

		do while not rs.eof
		mailto=rs("email")
			if EmailFlag=0 then
				errmsg=errmsg+"<br>"+"<li>本同学录不支持发送邮件。"
				exit sub
			elseif EmailFlag=1 then
				call jmail()
			elseif EmailFlag=2 then
				call Cdonts()
			elseif EmailFlag=3 then
				call aspemail()
			end if
		rs.movenext
		loop
	end if

if SendMailStatus="OK" then
		msg="邮件发送成功"
else
		msg="<br>"+"<li>由于以下原因邮件发送失败!</li>"
		msg=msg+"<br>"&SendMailStatus
end if

response.write ""&msg&""

end sub
%>



⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -