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

📄 cxzy.asp

📁 在线教育
💻 ASP
字号:
<%@LANGUAGE="VBSCRIPT"%>
<!--#include file="../Connections/conn.asp" -->
<%
Dim Recordset1__MMColParam
Recordset1__MMColParam = "无"
If (Request.Form("zy_studentid") <> "") Then 
  Recordset1__MMColParam = Request.Form("zy_studentid")
End If
%>
<%
Dim Recordset1
Dim Recordset1_cmd
Dim Recordset1_numRows

Set Recordset1_cmd = Server.CreateObject ("ADODB.Command")
Recordset1_cmd.ActiveConnection = MM_conn_STRING
Recordset1_cmd.CommandText = "SELECT * FROM tijiao WHERE zy_studentid LIKE ?" 
Recordset1_cmd.Prepared = true
Recordset1_cmd.Parameters.Append Recordset1_cmd.CreateParameter("param1", 200, 1, 50, "%" + Recordset1__MMColParam + "%") ' adVarChar

Set Recordset1 = Recordset1_cmd.Execute
Recordset1_numRows = 0
%>
<%
Dim Repeat1__numRows
Dim Repeat1__index

Repeat1__numRows = -1
Repeat1__index = 0
Recordset1_numRows = Recordset1_numRows + Repeat1__numRows
%>
<html>
<head>
<title>Untitled Document</title>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<link href="../Admin_Style.css" rel="stylesheet" type="text/css">
<style type="text/css">
<!--
body {
	background-color: #D6DFF7;
}
-->
</style>
<script language="jscript">
function check()
{
var notnull
notnull=true
if(document.form.zy_studentname.value=="")
{
alert("请输入姓名!")
notnull=false
return notnull
}
return notnull

}
</script>
</head>

<body text="#000000">
<form action="cxzy.asp" method="post" name="form">
  <table width="100%" border="0" align="center" cellpadding="2" cellspacing="1" class="border">
    <tr class="topbg"> 
      <td height="22" colspan="2" align="center"><strong>作 业 系 统 管 理</strong></td>
    </tr>
    <tr class="tdbg"> 
      <td width="70" height="30"><strong>查询:</strong></td>
      <td height="30">请输入学生帐号:
        <input type="text" name="zy_studentid" class="t3" size="20">
        <input type="submit" name="Submit" value="搜 索" class="t3">
      </td>
    </tr>
  </table>
</form>


<table width="95%" border="1" align="center" cellpadding="2" cellspacing="1" class="border">
  <tr class="title">
    <td height="25" colspan="6"><div align="center"><strong>搜索结果</strong></div></td>
  </tr>
  <% If Recordset1.EOF And Recordset1.BOF Then %>
    <tr class="tdbg">
      <td height="20" colspan="6" class="tdbg"><div align="center"> 暂时没有该学员 </div></td>
    </tr>
    <% End If ' end Recordset1.EOF And Recordset1.BOF %>

  <% If Not Recordset1.EOF Or Not Recordset1.BOF Then %>
    <tr>

<td width="100" height="20" align="center">学生帐号</td>
    <td width="82" align="center">学生姓名</td>
    <td width="56" align="center">作业次数</td>
    <td width="111" align="center">作业科目</td>
    <td width="111" align="center">任课教师</td>
    <td width="114" align="center">作业题目</td>
  </tr>
    <% 
While ((Repeat1__numRows <> 0) AND (NOT Recordset1.EOF)) 
%>
      <tr>
        <td width="100" height="20"><%=(Recordset1.Fields.Item("zy_studentid").Value)%></td>
        <td width="82" height="20"><%=(Recordset1.Fields.Item("zy_studentname").Value)%></td>
        <td width="56" height="20"><a href="pg_tjzyok.asp?id=<%=(Recordset1.Fields.Item("id").Value)%>"><%=(Recordset1.Fields.Item("zy_cs").Value)%></a></td>
        <td width="111" height="20"><%=(Recordset1.Fields.Item("zy_km").Value)%></td>
        <td width="111" height="20"><%=(Recordset1.Fields.Item("zy_teacher").Value)%></td>
        <td width="114" height="20"><%=(Recordset1.Fields.Item("zy_title").Value)%></td>
      </tr>
      <% 
  Repeat1__index=Repeat1__index+1
  Repeat1__numRows=Repeat1__numRows-1
  Recordset1.MoveNext()
Wend
%>

  <% End If ' end Not Recordset1.EOF Or NOT Recordset1.BOF %>
</table>
<br>


</body>
</html>
<%
Recordset1.Close()
Set Recordset1 = Nothing
%>

⌨️ 快捷键说明

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