?? classstudent.asp
字號:
<!--#include file="connectionstring.asp"-->
<%
IdClass=request.cookies("IdClass")
if IdClass="" then
response.write "非法操作!"
response.end
end if
Set Conn=Server.CreateObject("ADODB.Connection")
Conn.Open strConn
%>
<html>
<head>
</head>
<body background="Back1.jpg">
<%
sql="select * from stu where id like '" &IDClass& "%' order by id"
set rs=conn.execute(sql)
if not rs.eof then
%>
<table border="1" width="64%" align="center">
<tr>
<td width="30%" align="center"><b><font color="#008080" size="4">學生學號</font></b></td>
<td width="30%" align="center"><b><font color="#008080" size="4">學生姓名</font></b></td>
<td width="40%" align="center"><b><font color="#008080" size="4">班級</font></b></td>
</tr>
<%
while not rs.eof
%>
<tr>
<td width="26%" align="center"><font color="#008080">
<%
response.write rs("id")
%>
</td>
<td width="23%" align="center"><font color="#008080">
<%
sql = "select * from stu where id='" & rs("id") & "'"
set rs2=conn.execute(sql)
response.write rs2("name")
%>
</font></td>
<td width="51%" align="center"><font color="#008080">
<%
response.write rs2("class")
rs2.close
%>
</font></td>
</tr>
<%
rs.movenext
wend
rs.close
%>
</table>
<%
end if
conn.close
%>
<p align="center" style="margin-top: 0; margin-bottom: 0"> </p>
<form method="POST" action="classStudentshuru.asp" name="classStudentshuru.asp">
<p align="center" style="margin-top: 0; margin-bottom: 0"><input type="submit" value="輸入學生名單" name="a1"> </p>
</form>
<form method="POST" action="classStudentdel.asp" name="classStudentdel.asp">
<p align="center" style="margin-top: 0; margin-bottom: 0"><input type="submit" value="刪除學生名單" name="a1">
<p align="center" style="margin-top: 0; margin-bottom: 0"> </p>
<p align="center" style="margin-top: 0; margin-bottom: 0"><input type="button" value="返 回" onClick="history.back()">
</p>
</form>
</body>
</html>
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -