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

📄 adminclassadd.asp

📁 程序名称:酷虎网校友录 V1.0 (商业版)*(修改版) * 本软体为商业软件
💻 ASP
字号:
<!--#include file="conn.asp"-->
<!--#include file="inc/sessionadmin.asp"-->
<%
ClassName=Request.Form("ClassName")
ClassName1=Request.Form("ClassName1")
ClassName2=Request.Form("ClassName2")
ClassName3=Request.Form("ClassName3")
ProName=Request.Form("ProName")
ClassTeacher=Request.Form("ClassTeacher")
IF ClassName<>"" And ProName<>"" And ClassTeacher<>"" Then
SQL="Select * From 班级设置 Where 班级名称='"& ClassName &"'"
Set RS=Server.CreateObject("ADODB.Recordset")
RS.Open SQL,Connstr,3,2
IF RS.EOF Then
RS.ADDNew
RS("班级名称")=ClassName
RS("班主任")=ClassTeacher
RS("专业类型")=Int(ProName)
RS.Update
End IF
End IF

IF ClassName1<>"" Then

SQL="Select * From 班级设置 Where ID=" & Int(ClassName1)
Set RS=Server.CreateObject("ADODB.Recordset")
RS.Open SQL,Connstr,1,1
IF RS.Eof Then
SQL="Select * From 班级设置 Where ID=" & Int(ClassName2)
Set RS=Server.CreateObject("ADODB.Recordset")
RS.Open SQL,Connstr,3,2
IF Not RS.Eof Then
RS("班级名称")=ClassName1
RS.Update
End IF
End IF
End IF

IF ClassName3<>"" Then
SQL="Delete * From 班级设置 Where ID=" & Int(ClassName3)
Set RS=Server.CreateObject("ADODB.Recordset")
RS.Open SQL,Connstr,3,2
SQL="Delete * From 注册信息 Where 班别=" & Int(ClassName3)
Set RS=Server.CreateObject("ADODB.Recordset")
RS.Open SQL,Connstr,3,2

End IF
%>
<html>

<head>
<meta http-equiv="Content-Language" content="zh-cn">
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<meta name="GENERATOR" content="Microsoft FrontPage 4.0">
<meta name="ProgId" content="FrontPage.Editor.Document">
<!--#include file="inc/css.asp"-->
<title><%=WebSiteName%></title>
</head>
<body topmargin="0" background="images/bg.gif">
<!--#include file="admintop.asp"-->
<div align="center">
  <center>
  <table border="0" width="755" cellspacing="0" cellpadding="0">
    <tr>
      <td width="189" style="background-color: #FFFFFF; border-left: 1 solid #000000; border-top: 1 solid #000000; border-bottom: 1 solid #000000" valign="top"> 
		<!--#include file="aleft.asp"-->
      </td>
      <td width="562" style="background-color: #FFFFFF; border: 1 solid #000000" valign="top">
        <table border="0" width="100%" cellspacing="0" cellpadding="0">
          <tr>
            <td width="100%" height="25" bgcolor="#EDEDED" style="border-bottom: 1 solid #000000;">
              <table border="0" width="100%" cellspacing="0" cellpadding="0">
                <tr>
                  <td width="100%">
                    <p align="center">班级添加与管理</td>                 
                </tr>
              </table>
            </td>
          </tr>
          <tr>
            <td width="100%" valign="top">
            <div align="center">
              <table border="0" width="90%" cellspacing="0" cellpadding="0">
                <tr>
                  <td width="100%" height="8"></td>
                </tr>
              <center>
                <tr>
                  <td width="100%" valign="bottom" style="background-color: #EDEDED; border-top: 1 solid #000000; border-bottom: 1 solid #000000;" height="20">班级添加与管理--&gt;&gt;班级添加</td>
                </tr>
              </center>
              <form action="" method="post">
                <tr>
                  <td width="100%" valign="middle" align="right">
                    <table border="0" width="100%" cellspacing="0" cellpadding="0">
                      <tr>
                        <td width="24%" valign="middle" align="right">
                          <p style="margin-top: 10">增加新的班级名称:</td>
                        <td width="44%">
                          <p style="margin-top: 10"><input type=text name="ClassName" size=12 maxlength=12 style="background-attachment: scroll; background-repeat: repeat; font-size: 9pt; height: 18; width: 120; background-color: #FFFFFF; border: 1 solid #000000; background-position: none 0%"></td>
                        <td width="32%">
                          <p style="margin-top: 10"></td>
                      </tr>
                      <tr>
                        <td width="24%" valign="middle" align="right">
                          本班级所属的专业:</td>
                        <td width="44%">
                          <select size="1" name="ProName" style="background-attachment: scroll; background-repeat: repeat; font-size: 9pt; height: 23; width: 120; background-color: #FFFFFF; border: 1 solid #000000; background-position: none 0%">
                            <%      
                          SQL="Select ID,专业名称 From 专业设置"
                          Set RS=Server.CreateObject("ADODB.Recordset")
                          RS.Open SQL,Connstr,1,1
                          Do While Not RS.EOF
                            %>
                            <option value="<%=RS("ID")%>"><%=RS("专业名称")%></option>
                            <%
                          RS.MoveNext
                          Loop
                            %>
                            &nbsp;&nbsp;       
                          </select></td>
                        <td width="32%">
                        </td>
                      </tr>
                      <tr>
                        <td width="24%" valign="middle" align="right">
                          本班级班主任名字:</td>
                        <td width="44%">
                          <input type=text name="ClassTeacher" size=12 maxlength=12 style="background-attachment: scroll; background-repeat: repeat; font-size: 9pt; height: 18; width: 82; background-color: #FFFFFF; border: 1 solid #000000; background-position: none 0%"></td>
                        <td width="32%">
                        </td>
                      </tr>
                      <tr>
                        <td width="24%" valign="middle" align="right">
                          <p align="right" style="margin-bottom: 10">本班级的主页地址:</td>
                        <td width="44%">
                          <p style="margin-bottom: 10"><input type=text name="Homepage" size=12 maxlength=70 style="background-attachment: scroll; background-repeat: repeat; font-size: 9pt; height: 18; width: 120; background-color: #FFFFFF; border: 1 solid #000000; background-position: none 0%"></td>
                        <td width="32%">
                          <p style="margin-bottom: 10"><INPUT type=submit value=' 添 加 ' name=Submit style="background-color: #DDDDDD; background-repeat: repeat; background-attachment: scroll; font-size: 9pt; height: 18; width: 85; border: 1px groove #000000; background-position: 0% 50%"></td>
                      </tr>
                    </table>
                  </td>
                </tr>
                </form>
              <center>
                <center>
                <tr>
                  <td width="100%" valign="bottom" style="background-color: #EDEDED; border-top: 1 solid #000000; border-bottom: 1 solid #000000;" height="20">班级添加与管理--&gt;&gt;班级改名</td>
                </tr>
              </center>
              </center>
                <tr>
                  <td width="100%">
                    <table border="0" width="100%" cellspacing="0" cellpadding="0">
                    <form action="" method="post">
                      <tr>
                        <td width="6%">
                          <p style="margin-top: 10; margin-bottom: 10" align="right">将:</td>
              <center>
                  <td width="22%">
                    <p style="margin-top: 5; margin-bottom: 5">                                          
                          <select size="1" name="ClassName2" style="background-attachment: scroll; background-repeat: repeat; font-size: 9pt; height: 23; width: 107; background-color: #FFFFFF; border: 1 solid #000000; background-position: none 0%"><%
                          SQL="Select ID,班级名称 From 班级设置"
                          Set RS=Server.CreateObject("ADODB.Recordset")
                          RS.Open SQL,Connstr,1,1
                          Do While Not RS.EOF
                          %>
                          <option value="<%=RS("ID")%>"><%=RS("班级名称")%></option>
                          <%
                          RS.MoveNext
                          Loop
                          %>
                            &nbsp; </select></td>  
                  <td width="10%">
                    <p style="margin-top: 10; margin-bottom: 10">改名为:</td>
                  <td width="30%">
                    <p style="margin-top: 10; margin-bottom: 10"><input type=text name="ClassName1" size=12 maxlength=12 style="background-attachment: scroll; background-repeat: repeat; font-size: 9pt; height: 18; width: 96; background-color: #FFFFFF; border: 1 solid #000000; background-position: none 0%"></td>
                  <td width="32%">
                    <p style="margin-top: 10; margin-bottom: 10"><INPUT type=submit value=' 修 改 ' name=Submit style="background-color: #DDDDDD; background-repeat: repeat; background-attachment: scroll; font-size: 9pt; height: 18; width: 85; border: 1px groove #000000; background-position: 0% 50%">   
                  </td>
                        </tr>
                      </form>
                      </table>
                    </center>
                    </td>
                </tr>
                <center>
              </center>
              <center>
                <tr>
                  <td width="100%" valign="bottom" style="background-color: #EDEDED; border-top: 1 solid #000000; border-bottom: 1 solid #000000;" height="20">班级添加与管理--&gt;&gt;班级割除</td>
                </tr>
              </center>
              <form action="" method="post">
                <tr>
                  <td width="100%" height="8">
                    <table border="0" width="100%" cellspacing="0" cellpadding="0">
                      <tr>
                        <td width="6%">
                          <p style="margin-top: 10; margin-bottom: 10" align="right">将:</td>
                        <td width="22%">
                          <p style="margin-top: 10; margin-bottom: 10"><select size="1" name="ClassName3" style="background-attachment: scroll; background-repeat: repeat; font-size: 9pt; height: 23; width: 106; background-color: #FFFFFF; border: 1 solid #000000; background-position: none 0%"><%
                          SQL="Select ID,班级名称 From 班级设置"
                          Set RS=Server.CreateObject("ADODB.Recordset")
                          RS.Open SQL,Connstr,1,1
                          Do While Not RS.EOF
                          %>
                          <option value="<%=RS("ID")%>"><%=RS("班级名称")%></option>
                          <%
                          RS.MoveNext
                          Loop
                          %>
                          &nbsp; </select></td> 
                        <td width="40%">
                          <p style="margin-top: 10; margin-bottom: 10">从班级中割除。</td>
                        <td width="32%">
                          <p style="margin-top: 10; margin-bottom: 10"><INPUT type=submit value=' 割 除 ' name=Submit style="background-color: #DDDDDD; background-repeat: repeat; background-attachment: scroll; font-size: 9pt; height: 18; width: 85; border: 1px groove #000000; background-position: 0% 50%">   
                        </td>
                      </tr>
                    </table>
                  </td>
                </tr>
                </form>
                <tr>
                  <td width="100%" height="8">
                    <p>   
                  </td>
                </tr>
              <center>
              </table>
              </center>
            </div>
            </td>
          </tr>
          <tr>
            <td width="100%" valign="top" height="8">
            <p>
            </td>
          </tr>
        </table>
      </td>
    </tr>
  </table>
</div>
<!--#include file="bottom.asp"-->
</body>

</html>

⌨️ 快捷键说明

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