%@language=vbscript codepage=936 %>
<%
dim strFileName
const MaxPerPage=16
dim totalPut,CurrentPage,TotalPages
dim i,j
dim ArticleID
dim Title
dim sql,rs
dim BigClassName,SmallClassName,SpecialName
dim PurviewChecked
dim strAdmin,arrAdmin
PurviewChecked=false
Title=Trim(request("Title"))
ArticleID=Request("ArticleID")
BigClassName=Trim(request("BigClassName"))
SmallClassName=Trim(request("SmallClassName"))
SpecialName=trim(request("SpecialName"))
strFileName="webinfoManage.asp?BigClassName=" & BigClassName & "&SmallClassName=" & SmallClassName & "&SpecialName=" & SpecialName
if request("page")<>"" then
currentPage=cint(request("page"))
else
currentPage=1
end if
sql="select * from webinfo where ArticleID>0"
if session("purview")>4 then
sql=sql & " and Editor='" & Session("admin") & "' and Passed=false"
end if
if Title<>"" then
sql=sql & " and title like '%" & Title & "%' "
end if
if BigClassName<>"" then
sql=sql & " and BigClassName='" & BigClassName & "' "
if SmallClassName<>"" then
sql=sql & " and SmallClassName='" & SmallClassName & "' "
end if
else
if SpecialName<>"" then
sql=sql & " and SpecialName='" & SpecialName & "' "
end if
end if
sql=sql & " order by articleid desc"
Set rs= Server.CreateObject("ADODB.Recordset")
rs.open sql,conn,1,1
%>
| <%
dim sqlBigClass,sqlSmallClass,rsBigClass,rsSmallClass,sqlSpecial,rsSpecial
sqlBigClass="select * from BigClass1"
Set rsBigClass= Server.CreateObject("ADODB.Recordset")
rsBigClass.open sqlBigClass,conn,1,1
if rsBigClass.eof then
response.Write("还没有任何栏目,请首先添加栏目。")
end if
do while not rsBigClass.eof
if rsBigClass("BigClassName")=BigClassName then
response.Write("" & rsBigClass("BigClassName") & " | ")
if session("purview")=3 then
strAdmin=rsBigClass("Admin")
if Instr(strAdmin,"|")>0 then
arrAdmin=split(strAdmin)
for i=0 to ubound(arrAdmin)
if trim(arrAdmin(i))=session("admin") then
PurviewChecked=True
exit for
end if
next
else
if trim(strAdmin)=session("Admin") then
PurviewChecked=True
end if
end if
end if
else
response.Write("" & rsBigClass("BigClassName") & " | ")
end if
rsBigClass.movenext
loop
rsBigClass.close
set rsBigClass=nothing
%>
|
<%
rs.close
set rs=nothing
call CloseConn()
%>