<
SCRIPT
LANGUAGE
="JavaScript"
>
<!--
var global = new Object();
global.totalNum = 0 ; // 总记录条数
global.totalpage = 0 ;
global.pageNumber = 1 ;
global.listNum = 10 ;
global.rNum = ' <%=Request.QueryString("recordsNum")%> ' ;
if ( ! (parseInt(global.rNum) > 0 ))
global.rNum = 0 ;
function prePage() { // 上页
global.rNum = parseInt(global.rNum) - global.listNum;
if (global.rNum < 0 )
global.rNum = 0 ;
window.location.href = " stu_admin.asp?recordsNum= " + global.rNum;
}
function nextPage() { // 下页
global.rNum = parseInt(global.rNum) + global.listNum;
window.location.href = " stu_admin.asp?recordsNum= " + global.rNum;
}
function lastPage() { // 尾页
global.rNum = (global.totalPage - 1 ) * global.listNum;
window.location.href = " stu_admin.asp?recordsNum= " + global.rNum;
}
function firstPage() { // 守业
window.location.href = " stu_admin.asp " ;
}
// -->
</ SCRIPT >
<!-- #include file="conn.asp" -->
<%
dim curNum,totalNum
curNum = Request.QueryString( " recordsNum " )
curNum = curNum + 0
objComm.CommandText = " select COUNT(*) AS A from userstu "
set objRS = objComm.Execute
totalNum = objRS( " A " )
objComm.CommandText = " select * from userstu "
set objRS = objComm.Execute
objRS.Move curNum
%>
< SCRIPT LANGUAGE ="JavaScript" >
<!--
global.totalNum = ' <%=totalNum%> ' ;
global.totalPage = parseInt(global.totalNum / global.listNum);
if (global.totalNum % global.listNum != 0 )
global.totalPage ++ ;
// -->
</ SCRIPT >
< link type ="text/css" rel ="stylesheet" href ="style.css" />
< style type ="text/css" >
<!--
body {
margin-left : 10px ;
}
.STYLE2 { color : #000000 }
-->
</ style >< table width ="850" height ="15" border ="0" cellpadding ="0" cellspacing ="0" >
< tr >
< td width ="373" >< form id ="form1" name ="form1" method ="post" action ="" >
请输入关键字:
< input type ="text" name ="textfield" />
< select name ="select" >
< option > 姓名 </ option >
< option > 学号 </ option >
< option > 系别 </ option >
</ select >
< input type ="submit" name ="Submit" value ="搜索" />
</ form >
</ td >
< td width ="309" align ="right" >< a href ="stu_admin.asp" target ="_self" > 【查看记录】 </ a >< a href ="stu_add.asp" target ="_self" > 【添加记录】 </ a ></ td >
</ tr >
< tr >< td colspan ="2" >< hr color ="#999999" size ="0" /></ td ></ tr >
</ table >
< table border ="0" cellspacing ="1" width ="600" >
< tr >< td colspan =3 align =center >
</ td ></ tr >
</ table >
< table align =center >
< tr >
< td >
< span style ="cursor:hand;color:#0000FF" >
< font onclick ='firstPage()' > 首页 </ font >
</ span >
</ td >
< td >
< span id ='btn2' style ="cursor:hand;color:#0000FF" >
< font onclick ='prePage()' > 上一页 </ font >
</ span >
</ td >
< td >
< span id ='btn1' style ="cursor:hand;color:#0000FF" >
< font onclick ='nextPage()' > 下一页 </ font >
</ span >
</ td >
< td >
< span style ="cursor:hand;color:#0000FF" >
< font onclick ='lastPage()' > 尾页 </ font >
</ span >
</ td >
</ tr >
</ table >
< table border =0 cellspacing =1 bgcolor =#000000 >
< tr >
< td width ="100" align ="center" bgcolor =#33CCFF >< span class ="STYLE2" > 姓名 </ span ></ td >
< td width ="100" align ="center" bgcolor =#33CCFF > 学号 </ td >
< td width ="100" align ="center" bgcolor =#33CCFF > 密码 </ td >
< td width ="200" align ="center" bgcolor =#33CCFF > 邮件 </ td >
< td width ="120" align ="center" bgcolor =#33CCFF > 系别 </ td >
< td width ="100" align ="center" bgcolor =#33CCFF > 分数 </ td >
< td width ="30" align ="center" bgcolor =#33CCFF > 删除 </ td >
< td width ="30" align ="center" bgcolor =#33CCFF > 修改 </ td >
</ tr >
<%
dim i
i = 0
while not objRS.eof And i < 10
%>
< tr class ="<%=classtype%>" >
< td bgcolor =#ffffff > <% = objRS( " name " ) %> </ td >
<!--
var global = new Object();
global.totalNum = 0 ; // 总记录条数
global.totalpage = 0 ;
global.pageNumber = 1 ;
global.listNum = 10 ;
global.rNum = ' <%=Request.QueryString("recordsNum")%> ' ;
if ( ! (parseInt(global.rNum) > 0 ))
global.rNum = 0 ;
function prePage() { // 上页
global.rNum = parseInt(global.rNum) - global.listNum;
if (global.rNum < 0 )
global.rNum = 0 ;
window.location.href = " stu_admin.asp?recordsNum= " + global.rNum;
}
function nextPage() { // 下页
global.rNum = parseInt(global.rNum) + global.listNum;
window.location.href = " stu_admin.asp?recordsNum= " + global.rNum;
}
function lastPage() { // 尾页
global.rNum = (global.totalPage - 1 ) * global.listNum;
window.location.href = " stu_admin.asp?recordsNum= " + global.rNum;
}
function firstPage() { // 守业
window.location.href = " stu_admin.asp " ;
}
// -->
</ SCRIPT >
<!-- #include file="conn.asp" -->
<%
dim curNum,totalNum
curNum = Request.QueryString( " recordsNum " )
curNum = curNum + 0
objComm.CommandText = " select COUNT(*) AS A from userstu "
set objRS = objComm.Execute
totalNum = objRS( " A " )
objComm.CommandText = " select * from userstu "
set objRS = objComm.Execute
objRS.Move curNum
%>
< SCRIPT LANGUAGE ="JavaScript" >
<!--
global.totalNum = ' <%=totalNum%> ' ;
global.totalPage = parseInt(global.totalNum / global.listNum);
if (global.totalNum % global.listNum != 0 )
global.totalPage ++ ;
// -->
</ SCRIPT >
< link type ="text/css" rel ="stylesheet" href ="style.css" />
< style type ="text/css" >
<!--
body {
margin-left : 10px ;
}
.STYLE2 { color : #000000 }
-->
</ style >< table width ="850" height ="15" border ="0" cellpadding ="0" cellspacing ="0" >
< tr >
< td width ="373" >< form id ="form1" name ="form1" method ="post" action ="" >
请输入关键字:
< input type ="text" name ="textfield" />
< select name ="select" >
< option > 姓名 </ option >
< option > 学号 </ option >
< option > 系别 </ option >
</ select >
< input type ="submit" name ="Submit" value ="搜索" />
</ form >
</ td >
< td width ="309" align ="right" >< a href ="stu_admin.asp" target ="_self" > 【查看记录】 </ a >< a href ="stu_add.asp" target ="_self" > 【添加记录】 </ a ></ td >
</ tr >
< tr >< td colspan ="2" >< hr color ="#999999" size ="0" /></ td ></ tr >
</ table >
< table border ="0" cellspacing ="1" width ="600" >
< tr >< td colspan =3 align =center >
</ td ></ tr >
</ table >
< table align =center >
< tr >
< td >
< span style ="cursor:hand;color:#0000FF" >
< font onclick ='firstPage()' > 首页 </ font >
</ span >
</ td >
< td >
< span id ='btn2' style ="cursor:hand;color:#0000FF" >
< font onclick ='prePage()' > 上一页 </ font >
</ span >
</ td >
< td >
< span id ='btn1' style ="cursor:hand;color:#0000FF" >
< font onclick ='nextPage()' > 下一页 </ font >
</ span >
</ td >
< td >
< span style ="cursor:hand;color:#0000FF" >
< font onclick ='lastPage()' > 尾页 </ font >
</ span >
</ td >
</ tr >
</ table >
< table border =0 cellspacing =1 bgcolor =#000000 >
< tr >
< td width ="100" align ="center" bgcolor =#33CCFF >< span class ="STYLE2" > 姓名 </ span ></ td >
< td width ="100" align ="center" bgcolor =#33CCFF > 学号 </ td >
< td width ="100" align ="center" bgcolor =#33CCFF > 密码 </ td >
< td width ="200" align ="center" bgcolor =#33CCFF > 邮件 </ td >
< td width ="120" align ="center" bgcolor =#33CCFF > 系别 </ td >
< td width ="100" align ="center" bgcolor =#33CCFF > 分数 </ td >
< td width ="30" align ="center" bgcolor =#33CCFF > 删除 </ td >
< td width ="30" align ="center" bgcolor =#33CCFF > 修改 </ td >
</ tr >
<%
dim i
i = 0
while not objRS.eof And i < 10
%>
< tr class ="<%=classtype%>" >
< td bgcolor =#ffffff > <% = objRS( " name " ) %> </ td >