📄 hover_down_manage.asp
字号:
<!--#include file="toptable.asp"-->
<%
'=================================
' 良精科技企业管理系统
' QQ在线客服:65961930 82993936
' 咨询定购Tel:010-81991660
' asp3721@hotmail.com
' www.liangjing.net
' copyright(c)2001-2008 HoverCms 2007特别版
'=================================
%>
<%
dim strFileName
const MaxPerPage=20
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
strFileName="Hover_Down_Manage.asp?BigClassName=" & BigClassName & "&SmallClassName=" & SmallClassName & "&SpecialName=" & SpecialName
BigClassName=Trim(request("BigClassName"))
SmallClassName=Trim(request("SmallClassName"))
if request("page")<>"" then
currentPage=cint(request("page"))
else
currentPage=1
end if
sql="select * from Hover_download "
if BigClassName<>"" then
sql=sql & "where BigClassName='" & BigClassName & "' "
if SmallClassName<>"" then
sql=sql & " and SmallClassName='" & SmallClassName & "' "
end if
end if
sql=sql & " order by id desc"
Set rs= Server.CreateObject("ADODB.Recordset")
rs.open sql,conn,1,1
%>
<SCRIPT language=javascript>
function unselectall()
{
if(document.del.chkAll.checked){
document.del.chkAll.checked = document.del.chkAll.checked&0;
}
}
function CheckAll(form)
{
for (var i=0;i<form.elements.length;i++)
{
var e = form.elements[i];
if (e.Name != "chkAll")
e.checked = form.chkAll.checked;
}
}
function ConfirmDel()
{
if(confirm("确定要删除选中的产品吗?一旦删除将不能恢复!"))
return true;
else
return false;
}
</SCRIPT>
<!-- #include file="Inc/Head.asp" -->
<br>
<table width="97%" border="0" align="center" cellpadding="3" cellspacing="1" class="tableBorder">
<tr>
<td colspan="7" align="center" valign="top" class="title"> <strong>下 载 管 理</strong> </td>
</tr>
<tr> <td height="25" colspan="7" bgcolor="#A4B6D7" class="title2">|
<%
dim sqlBigClass,sqlSmallClass,rsBigClass,rsSmallClass,sqlSpecial,rsSpecial
sqlBigClass="select * From Hover_BigClass_down"
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("<a href='Hover_Down_Manage.asp?BigClassName=" & rsBigClass("BigClassName") & "'><font color='red'>" & rsBigClass("BigClassName") & "</font></a> | ")
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("<a href='Hover_Down_Manage.asp?BigClassName=" & rsBigClass("BigClassName") & "'>" & rsBigClass("BigClassName") & "</a> | ")
end if
rsBigClass.movenext
loop
rsBigClass.close
set rsBigClass=nothing
%>
</td>
</tr>
<%
if BigClassName<>"" then
sqlSmallClass="select * from Hover_SmallClass_down where BigClassName='" & BigClassName & "'"
Set rsSmallClass= Server.CreateObject("ADODB.Recordset")
rsSmallClass.open sqlSmallClass,conn,1,1
if not (rsSmallClass.bof and rsSmallClass.eof) then
response.write "<tr class='tdbg'><td bgcolor='#C0C0C0'>"
do while not rsSmallClass.eof
if rsSmallClass("SmallClassName")=SmallClassName then
response.Write(" <a href='Hover_Down_Manage.asp?BigClassName=" & rsSmallClass("BigClassName") & "&SmallClassName=" & rsSmallClass("SmallClassName") & "'><font color='red'>" & rsSmallClass("SmallClassName") & "</font></a> ")
if session("purview")=4 then
strAdmin=rsSmallClass("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(" <a href='Hover_Down_Manage.asp?BigClassName=" & rsSmallClass("BigClassName") & "&SmallClassName=" & rsSmallClass("SmallClassName") & "'>" & rsSmallClass("SmallClassName") & "</a> ")
end if
rsSmallClass.movenext
loop
response.write "</td></tr>"
end if
rsSmallClass.close
set rsSmallClass=nothing
end if
%>
<form name="del" method="Post" action="Hover_Down_ArticleDel.asp" onSubmit="return ConfirmDel();">
<tr>
<td height="25" colspan="6" bgcolor="#A4B6D7" class="table"><a href="Hover_Down_Manage.asp"> 下载资讯管理</a>
>>
<%
if request.querystring="" then
response.write "所有下载"
else
if request("Query")<>"" then
if Title<>"" then
response.write "名称中含有“<font color=blue>" & Title & "</font>”的产品"
else
response.Write("所有下载")
end if
else
if BigClassName<>"" then
response.write "<a href='Hover_Down_Manage.asp?BigClassName=" & BigClassName & "'>" & BigClassName & "</a> >> "
if SmallClassName<>"" then
response.write "<a href='Hover_Down_Manage.asp?BigClassName=" & BigClassName & "&SmallClassName=" & SmallClassName & "'>" & SmallClassName & "</a>"
else
response.write "所有小类"
end if
end if
end if
end if
%>
</td>
<td width="121" bgcolor="#A4B6D7" class="table">
<%
if rs.eof and rs.bof then
response.write "共找到 0 条下载</td></tr></table>"
else
totalPut=rs.recordcount
if currentpage<1 then
currentpage=1
end if
if (currentpage-1)*MaxPerPage>totalput then
if (totalPut mod MaxPerPage)=0 then
currentpage= totalPut \ MaxPerPage
else
currentpage= totalPut \ MaxPerPage + 1
end if
end if
response.Write "共找到 " & totalPut & " 条下载"
%>
</td>
</tr>
<%
if currentPage=1 then
showContent
showpage strFileName,totalput,MaxPerPage,true,false,"条下载"
else
if (currentPage-1)*MaxPerPage<totalPut then
rs.move (currentPage-1)*MaxPerPage
dim bookmark
bookmark=rs.bookmark
showContent
showpage strFileName,totalput,MaxPerPage,true,false,"条下载"
else
currentPage=1
showContent
showpage strFileName,totalput,MaxPerPage,true,false,"条下载"
end if
end if
end if
%>
<%
sub showContent
dim i
i=0
%>
<tr bgcolor="#A4B6D7" class="title">
<td width="98" height="25" align="center" class="items">选中</td>
<td width="86" height="25" align="center" class="items">ID</td>
<td width="341" align="center" class="items" >下载标题</td>
<td width="98" align="center" class="items" >所属一级分类</td>
<td width="102" align="center" class="items" >所属二级分类</td>
<td width="89" align="center" class="items" >加入时间</td>
<td width="121" align="center" class="items" >操作</td>
</tr>
<%do while not rs.eof%>
<tr class="tdbg">
<td width="98" height="22" align="center" bgcolor="#A4B6D7" class="table">
<input name='ID' type='checkbox' onClick="unselectall()" id="ID" value='<%=cstr(rs("ID"))%>'>
</td>
<td width="86" align="center" bgcolor="#ECF5FF" class="table"><%=rs("id")%></td>
<td bgcolor="#ECF5FF" class="table"><a href="../DownloadShow.asp?ID=<%=rs("id")%>" target="_blank"><%=left(rs("title"),18)%></a></td>
<td bgcolor="#ECF5FF" class="table">
<div align="center"><%=rs("BigClassName")%></div></td>
<td bgcolor="#ECF5FF" class="table">
<div align="center"><%=rs("SmallClassName")%></div></td>
<td align="center" bgcolor="#ECF5FF" class="table"><%= FormatDateTime(rs("infotime"),2) %> </td>
<td width="121" align="center" bgcolor="#ECF5FF" class="table"> <a href="Hover_Down_admin_modi.asp?ID=<%=rs("id")%>">修改</a>
<a href="Hover_Down_admin_del.asp?ID=<%=rs("ID")%>&Action=Del" onClick="return ConfirmDel();">删除</a> </td>
</tr>
<%
i=i+1
if i>=MaxPerPage then exit do
rs.movenext
loop
%>
<tr>
<td height="30" colspan="2" class="table"><input name="chkAll" type="checkbox" id="chkAll" onclick=CheckAll(this.form) value="checkbox">
选中本页显示的所有下载</td>
<td colspan="5" class="table"><input name="submit" type='submit' class="btn2" value='删除选定的下载' <%if session("purview")>=3 and session("purview")<=4 and PurviewChecked=False then response.write "disabled"%>>
<input name="Action" type="hidden" id="Action" value="Del"></td>
</tr>
<%
end sub
%>
</form>
<tr class="tdbg">
<form name="searchsoft" method="get" action="Hover_Down_Manage.asp">
<td height="30" colspan="7" class="table"> <strong>查找下载:</strong> <input name="Title" type="text" class=smallInput id="Title3" size="20" maxlength="50">
<input name="Query" type="submit" class="btn" id="Query" value="查 询">
请输入下载名称。如果为空,则查找所有下载。</td>
</form>
</tr>
</table>
<!-- #include file="Inc/Foot.asp" -->
<%
rs.close
set rs=nothing
call CloseConn()
%>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -