📄 admin_classsort.asp
字号:
<!--#include file="session.asp"-->
<%checkAdmin2%>
<!--#include file="conn.asp"-->
<%
Dim ID,ClassID,TheClass
ID=request("ID")
ClassID=request("ClassID")
TheClass=Request("WhatClass")
if TheClass="BigClass" then sql="select * from BigClass where BigClassID="&ClassID
if TheClass="SmallClass" then sql="select * from SmallClass where SmallClassID="&ClassID
if TheClass="Special" then sql="select * from Special where SpecialID="&ClassID
rs.open sql,conn,3,3
if request("sort")="up" then
if TheClass="BigClass" then rs("BigClassID")=rs("BigClassID")-1
if TheClass="SmallClass" then rs("SmallClassID")=rs("SmallClassID")-1
if TheClass="Special" then rs("SpecialID")=rs("SpecialID")-1
else
if TheClass="BigClass" then rs("BigClassID")=rs("BigClassID")+1
if TheClass="SmallClass" then rs("SmallClassID")=rs("SmallClassID")+1
if TheClass="Special" then rs("SpecialID")=rs("SpecialID")+1
end if
rs.update
rs.close
if request("sort")="up" then
if TheClass="BigClass" then sql="select * from BigClass where BigClassID="&ClassID-1&" and ID<>"&ID
if TheClass="SmallClass" then sql="select * from SmallClass where SmallClassID="&ClassID-1&" and ID<>"&ID
if TheClass="Special" then sql="select * from Special where SpecialID="&ClassID-1&" and ID<>"&ID
else
if TheClass="BigClass" then sql="select * from BigClass where BigClassID="&ClassID+1&" and ID<>"&ID
if TheClass="SmallClass" then sql="select * from SmallClass where SmallClassID="&ClassID+1&" and ID<>"&ID
if TheClass="Special" then sql="select * from Special where SpecialID="&ClassID+1&" and ID<>"&ID
end if
rs.open sql,conn,3,3
if request("sort")="up" then
if TheClass="BigClass" then rs("BigClassID")=rs("BigClassID")+1
if TheClass="SmallClass" then rs("SmallClassID")=rs("SmallClassID")+1
if TheClass="Special" then rs("SpecialID")=rs("SpecialID")+1
else
if TheClass="BigClass" then rs("BigClassID")=rs("BigClassID")-1
if TheClass="SmallClass" then rs("SmallClassID")=rs("SmallClassID")-1
if TheClass="Special" then rs("SpecialID")=rs("SpecialID")-1
end if
rs.update
rs.close
set rs=nothing
conn.close
set conn=nothing
response.redirect "admin_"&TheClass&"Mana.asp"
%>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -