📄 leitainame.asp
字号:
<!-- #include file="setup.asp" -->
<%
if Request.Cookies("username")=empty then
response.redirect "login.asp"
end if
if instr(Request.Cookies("username")," ")>0 then:error("<li>非法操作"):end if
sql="select * from [user] where username='"&Request.Cookies("username")&"'"
rs.Open sql,Conn,1,3
if Request.Cookies("userpass")<>rs("userpass") then
error2("密码错误!")
end if
rs.close
%>
<HTML>
<HEAD>
<title>打擂人员列表</title>
<link href=images/skins/<%=Request.Cookies("skins")%>/bbs.css rel=stylesheet>
</HEAD>
<BODY>
<SCRIPT>valigntop()</SCRIPT>
<table cellspacing="1" cellpadding="1" width="97%" align="center" border="0" class="a2"><tr><td height="25" class="a1" colspan="2"> ■<b> 擂台参赛人员列表</b></td></tr><tr>
<td class="a4"><table cellspacing="0" cellpadding="3" width="100%" border="0" style="border-left: 0px none; border-top: 0px none; border-bottom: 1px none"><tr><td><table border="0" cellpadding="0" cellspacing="0" width="100%">
<table width="98%" border="0" cellspacing="1" cellpadding="0" height="20" class="a2">
<tr align="center">
<td width="20%" height="25" class="a1">备战名单</td>
<td width="14%" height="25" class="a1">今天参战</td>
<td width="14%" height="25" class="a1">使用武器</td>
<td width="14%" height="25" class="a1">使用暗器</td>
<td width="14%" height="25" class="a1">使用防具</td>
<td width="8%" height="25" class="a1">参战</td>
<td width="8%" height="25" class="a1">战胜</td>
<td width="8%" height="25" class="a1">战败</td>
</tr>
<%
Set rs1 = Server.CreateObject("ADODB.Recordset")
rs.Open "select * from [leitai] where bwbeizhan>0",Conn,1,3
pagesetup=10 '设定每页的显示数量
rs.pagesize=pagesetup
TotalPage=rs.pagecount '总页数
PageCount = cint(Request.QueryString("ToPage"))
if PageCount <1 then PageCount = 1
if PageCount > TotalPage then PageCount = TotalPage
if TotalPage>0 then rs.absolutepage=PageCount '跳转到指定页数
i=0
Do While Not RS.EOF and i<pagesetup
i=i+1
if day(rs("bwnow"))<>day(date) and rs("bwbeizhan")=2 then
rs("bwbeizhan")=1
rs("bwtime")=0
rs.update
end if
if rs.eof then
Response.Write "没有人报名参战"
else
rs1.Open "select * from [mytools] where username='"&rs("bwname")&"' and use = 2",Conn,1,3
if rs1.eof then
wuqi="赤手空拳"
else
wuqi=rs1("toolname")
end if
rs1.close
rs1.Open "select * from [mytools] where username='"&rs("bwname")&"' and use = 3",Conn,1,3
if rs1.eof then
anqi="赤手空拳"
else
anqi=rs1("toolname")
end if
rs1.close
rs1.Open "select * from [mytools] where username='"&rs("bwname")&"' and use = 4",Conn,1,3
if rs1.eof then
fangju="赤手空拳"
else
fangju=rs1("toolname")
end if
rs1.close
%>
<tr align="center">
<td width="20%" height="21" class="a4"><a href=# onclick=javascript:open('profile.asp?username=<%=rs("bwname")%>','','')><%=rs("bwname")%></a></td>
<td width="14%" height="21" class="a3"><%=rs("bwtime")%></td>
<td width="14%" height="21" class="a4"><a href=# onclick=javascript:open('showtool.asp?toolname=<%=wuqi%>','','width=220,height=170')><%=wuqi%></a></td>
<td width="14%" height="21" class="a4"><a href=# onclick=javascript:open('showtool.asp?toolname=<%=anqi%>','','width=220,height=170')><%=anqi%></a></td>
<td width="14%" height="21" class="a4"><a href=# onclick=javascript:open('showtool.asp?toolname=<%=fangju%>','','width=220,height=170')><%=fangju%></a></td>
<td width="8%" height="21" class="a4"><%=rs("bwtopic")%></td>
<td width="8%" height="21" class="a3"><font color=#FF0000><%=rs("zhstopic")%></font></td>
<td width="8%" height="21" class="a4"><font color=#00FF00><%=rs("bwtopic")-rs("zhstopic")%></font></td>
</tr>
<%
end if
rs.movenext
loop
rs.close
%></table>
<br><center>
Page:[
<script>
PageCount=<%=TotalPage%> //总页数
topage=<%=PageCount%> //当前停留页
for (var i=1; i <= PageCount; i++) {
if (i <= topage+3 && i >= topage-3 || i==1 || i==PageCount){
if (i > topage+4 || i < topage-2 && i!=1 && i!=2 ){document.write(" ... ");}
if (topage==i){document.write(" "+ i +" ");}
else{
document.write("<a href=?topage="+i+">"+ i +"</a> ");
}
}
}
</script>
]<br></center>
</table></td></tr></table></td></tr></table>
<SCRIPT>valignbottom()</SCRIPT>
</body>
</HTML>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -