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

📄 admin_user.asp

📁 在线考试系统源码实现远程判卷
💻 ASP
字号:
<!--#include file="inc/open.asp" -->
<!--#include file="inc/md5.inc" -->
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title>用户管理</title>
<!--#include file="inc/css.css" -->
</head>

<body>
<!--#include file="top.asp" -->
<!--#include file="menu.asp" -->
<%
if session("zzteacher")=false then
  login_user=request.form("login_user")
  if login_user="" then login_user=" " end if
  login_pass=request.form("login_pass")
  if login_pass="" then login_pass=" " end if
  login_pass=ucase(md5(login_pass))
  str="select * from user_te where teacher_user='"&login_user&"' and teacher_pass='"&login_pass&"'"
  'response.write str
  set rs=conn.execute(str)
  if rs.eof then
      session("zzteacher")=false
	  session("adminadmin")=false
   else
      if rs("teacher_class")="超级管理员" then
	     session("zzteacher")=true
		 session("adminadmin")=true
	  end if
	  if rs("teacher_class")="教师" then
	     session("zzteacher")=true
      end if
   end if
end if
%>
<table width="770" border="1" align="center" cellpadding="0" cellspacing="0" bordercolor="ff99cc" bgcolor="edebeb">
  <tr>
    <td width="200" valign="top"> 
      <table width="163" border="0" align="center" cellpadding="0" cellspacing="0">
        <tr>
          <td height="6">
<div align="center" class="unnamed6"> </div></td>
        </tr>
        <tr> 
          <td height="10" background="images/nxmt_lj_46.gif"><span class="unnamed10">  
            </span> <div align="center"></div>
            <div align="center"></div></td>
        </tr>
        <tr> 
          <td background="images/nxmt_lj_44.gif"><div align="center" class="unnamed14">管理员登录</div></td>
        </tr>
        <tr> 
          <td background="images/nxmt_lj_44.gif">
<%if session("zzteacher")=flase then%>
		     <form action="admin_user.asp" method="post" name="form1" class="unnamed12">
              <div align="center">
                <p>用户名: 
                  <input name="login_user" type="text" id="login_user" size="12" maxlength="15">
                </p>
                <p> 密 码: 
                  <input name="login_pass" type="password" id="login_pass" size="12" maxlength="15">
                  <br>
                  <br>
                  <input type="submit" name="Submit" value=" 登 录 ">
                </p>
              </div>
            </form>
<%else 
     if session("adminadmin")=true then
	     response.write "<br> <br><center class=unnamed12>超级管理员已登录"
	 else
	     response.write "<br> <br><center class=unnamed12>管理员已登录"
	 end if
	 response.write "  <a href=quit.asp>退出</a>" 
	 response.write "<br><br><a href=stlx_setup.asp?lx=no>设置为没有练习状态</a>"
	 response.write "<br><br><a href=stlx_setup.asp?lx=yes>设置为练习状态</a>"
end if%>
			</td>
        </tr>
        <tr> 
          <td height="11" background="images/nxmt_lj_45.gif"> <div align="center" class="unnamed10"> </div></td>
        </tr>
      </table>
<% if session("adminadmin")=false then%>
      <p align="center" class="unnamed14">  超级管理员登录后<br>
        可修改用户的信息。</p>
<% end if%>		
		</td>
    <td width="570" valign="top"> <div align="center">
<%if session("adminadmin")=true then%>
        <span class="unnamed6">  </span><span class="unnamed14"><br>
        用户列表  <a href="insert_user.asp">添加用户</a>  <a href="system/setup.asp">系统设置</a></span></div>
      <table width="80%" border="1" align="center" cellpadding="2" cellspacing="0">
        <tr bgcolor="#999999" class="unnamed12"> 
          <td width="20%"> <div align="center">用户名</div></td>
          <td width="20%"> <div align="center">姓名</div></td>
          <td width="20%"> <div align="center">用户类别</div></td>
          <td width="20%"><div align="center">修改</div></td>
          <td width="20%"><div align="center">删除</div></td>
        </tr>
        <%str="select * from user_te"
  set rs=conn.execute(str)
  do while not rs.eof%>
        <tr class="unnamed12"> 
          <td width="20%"><div align="center"><%=rs("teacher_user")%></div></td>
          <td width="20%"><div align="center"><%=rs("teacher_name")%></div></td>
          <td width="20%"><div align="center"><%=rs("teacher_class")%></div></td>
          <td width="20%"><div align="center"><a href=admin_edit.asp?edit_id=<%=rs("id")%>>修改</a></div></td>
          <td width="20%"><div align="center"><a href=admin_del.asp?del_id=<%=rs("id")%>>删除</a></div></td>
        </tr>
        <%rs.movenext
  loop%>
      </table>
<%else%>
<form name="form1" method="post" action=teacher_edit.asp>
        <table width="500" border="0" cellspacing="0" cellpadding="0">
          <tr> 
            <td class="unnamed6"> </td>
          </tr>
        </table>
        <table width="500" border="1" align="center" cellpadding="1" cellspacing="0">
          <tr> 
            <td height="40" colspan="2" bgcolor="#999999" class="unnamed14"><div align="center"><strong>修 
                改 管 理 员 信 息</strong></div></td>
          </tr>
          <tr class="unnamed12"> 
            <td width="50%" height="30"> <div align="center">用 户 名:</div></td>
            <td width="50%" height="30"> <div align="left">    
                <input name="edit_user" type="text" id="edit_user" size="20" maxlength="15">
                *</div></td>
          </tr>
          <tr class="unnamed12"> 
            <td width="50%" height="30"> <div align="center">真实姓名:</div></td>
            <td width="50%" height="30"> <div align="left">    
                <input name="edit_name" type="text" id="edit_name" size="20" maxlength="15">
              </div></td>
          </tr>
          <tr class="unnamed12">
            <td height="30"><div align="center">原来密码:</div></td>
            <td height="30"> <div align="left">    
                <input name="edit_oldpass" type="password" id="edit_oldpass" size="20" maxlength="15">
                *</div></td>
          </tr>
          <tr class="unnamed12"> 
            <td width="50%" height="30"> <div align="center">新 密 码:</div></td>
            <td width="50%" height="30"> <div align="left">    
                <input name="edit_pass" type="password" id="edit_pass" size="20" maxlength="15">
              </div></td>
          </tr>
          <tr class="unnamed12"> 
            <td width="50%" height="30"> <div align="center">验证密码:</div></td>
            <td width="50%" height="30"> <div align="left">    
                <input name="edit_pass1" type="password" id="edit_pass1" size="20" maxlength="15">
              </div></td>
          </tr>
          <tr class="unnamed12"> 
            <td width="50%" height="30"> <div align="center">用户类别:</div></td>
            <td width="50%" height="30"> <div align="left">    
                <select name="edit_class" id="edit_class">
                  <option value="教师" selected>教师</option>
                </select>
              </div></td>
          </tr>
          <tr> 
            <td height="29" colspan="2"> <div align="center"> 
                <INPUT name="button" type=button class=unnamed5 onclick=javascript:history.go(-1) value=" 返 回 ">
                   
                <input type="submit" name="Submit2" value=" 确 定 ">
                   
                <input type="reset" name="Submit3" value=" 重 填 ">
              </div></td>
          </tr>
        </table>
        <table width="500" border="0" align="center" cellpadding="0" cellspacing="0">
          <tr> 
            <td class="unnamed6"> </td>
          </tr>
          <tr> 
            <td><div align="center"><span class="unnamed12"><font color="#FF0000">带 
                * 部分为必填</font></span> </div>
              <div align="center" class="unnamed14"> </div></td>
          </tr>
        </table>
      </form>
<%
end if
conn.close%>
	  </td>
  </tr>
</table>
<!--#include file="inc/bottom.inc" -->
</body>
</html>

⌨️ 快捷键说明

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