📄 xsxx_list.asp
字号:
<%@LANGUAGE="VBSCRIPT" CODEPAGE="936"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<!--#include file = "conn.asp"-->
<html xmlns="http://www.w3.org/1999/xhtml">
<%
dim rs
dim sql
dim StuXH,StuXM,StuXB,StuCSSJ,StuZY,StuZXF,StuBZ
%>
<%
Function genSQLstr()
if request.Form("StuXH") <> "" then
sql = sql + "where XH like '%" + Request("StuXH") + "%'"
else
sql = sql + "where XH like '%'"
end if
if request.Form("StuXM") <> "" then
sql = sql + "and XM like '%" + Request("StuXM") + "%'"
end if
if request.Form("StuZY") <> "" then
sql = sql + "and ZY like '%" + Request("StuZY") + "%'"
end if
end function
%>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
<title>学生信息查询</title>
<style>
@import URL("xscj.css");
</style>
</head>
<body>
<div align = "center">
<%
set rs = server.CreateObject("ADODB.recordset")
genSQLstr()
'response.Write(""&sql&"")
sql = "select * from XS "&sql&""
rs.open sql,conn,1,1
%>
<span class="pagenote1">学生信息查询</span>
</div>
<hr />
<form name="StuForm" action="" method="post">
<table width="460" align="center">
<tr>
<td bordercolor="#000000" bgcolor="#99CCCC">
学号:<input name="StuXH" type="text" size="6" />
姓名:<input name="StuXM" type="text" size="8" />
专业:<input name="StuZY" type="text" size="16" />
<input name="StuUp" value="查询" type="submit" />
</td></tr></table>
</form>
<div align="center">
<table align="center" bordercolor="#000000" border="1" cellpadding="0" cellspacing="0" bordercolorlight="#000000" bordercolordark="#FFFFFF">
</div>
<tr class="tableth1">
<td height="22" width="80">学号</td>
<td height="22" width="90">姓名</td>
<td height="22" width="30">性别</td>
<td height="22" width="80">出生日期</td>
<td height="22" width="120">专业</td>
<td height="22" width="60">总学分</td>
</tr>
<%
while not rs.eof
StuXH = rs("XH")
StuXM = rs("XM")
if rs("XB") = true then
StuXB = "男"
else
StuXB = "女"
end if
StuCSSJ = rs("CSSJ")
StuZY = rs("ZY")
StuZXF = rs("ZXF")
%>
<tr>
<td><%=StuXH%></td>
<td>
<a target="new" href="xscj_list.asp?XH1=<%=StuXH%>"><%=StuXM%></a>
</td>
<td><%=StuXB%></td>
<td><%=StuCSSJ%></td>
<td><%=StuZY%></td>
<td><%=StuZXF%></td>
</tr>
<%
rs.movenext
wend
%>
</table>
</body>
</html>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -