?? admin_zx.asp
字號:
<!--#include file="conn.asp" -->
<!--#include file="TurnPage.asp" -->
<!--#include file="admin_check.asp" -->
<%
call manager(session("grade"),session("adminname"),2)
Dim RowCount , order
RowCount = 50 '每頁顯示的記錄條數(shù)
set rs=server.CreateObject("adodb.recordset")
order=trim(request("order"))
xdel=trim(request("xdel"))
select case xdel
'刪除某資訊
case "del"
rs.open "delete from xinxi where 編號=" &trim(request("id")) ,conn,3,3
response.redirect "admin_zx.asp?x=dell&order=" &order
'刪除全部未審核資訊
case "delall"
rs.open "delete from xinxi where 審核=0",conn,3,3
response.write("<center>未審核資訊刪除成功!<a href='admin_zx.asp'>>>點(diǎn)擊這里返回<<</a></center>")
response.end
end select
select case order
'未審核資訊
case "notype"
rs.open "select * from xinxi where 審核=0 order by 編號 desc",conn,1,1
'已審核資訊
case "yestype"
rs.open "select * from xinxi where 審核=-1 order by 編號 desc",conn,1,1
'推薦資訊
case "tui"
rs.open "select * from xinxi where 審核=-1 and 推薦=-1 order by 城市,編號 desc",conn,1,1
'所有資訊(默認(rèn))
case else
rs.open "select * from xinxi order by 編號 desc",conn,1,1
end select
%>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title>后臺(tái)管理 - 資訊管理</title>
<link href="admin.css" rel="stylesheet" type="text/css">
</head>
<body>
<table width="960" border="0" align="center" cellpadding="0" cellspacing="0">
<tr>
<td width="160" valign="top">
<!--#include file="admin_left.asp" -->
</td>
<td width="800" align="center" valign="top">
<table width="800" border="0" cellpadding="3" cellspacing="1" bgcolor="#DFEAF2">
<tr bgcolor="#333333">
<td height="20" bgcolor="#FFFFFF">選擇:<a href="admin_zx.asp">所有資訊</a> |
<a href="?order=notype">未審核資訊</a> |
<a href="?order=yestype">已審核資訊</a> |
<a href="?order=tui">推薦資訊</a> | <a href="?order=delall">刪除所有未審核資訊</a> |
<a href="?order=<%=order%>&x=dell">顯示刪除按鈕</a></td>
</tr>
<tr bgcolor="#333333">
<td height="25" bgcolor="#FFFFFF" width="800"><% Call TurnPage(Rs,RowCount)%></td>
</tr>
<%
If Not rs.eof then
Do while Not rs.eof and RowCount>0 %>
<tr>
<td bgcolor="#FFFFFF" onMouseOver='this.style.backgroundColor="#DFEAF2"' onMouseOut='this.style.backgroundColor=""'>
<table border="1" cellpadding="2" cellspacing="0" style="border-collapse: collapse" width=800>
<tr>
<td width="170" height="30" bgcolor="#DFEAF2">名稱:<%=rs("名稱")%></td>
<td width="110">
<%set rscity=server.CreateObject("adodb.recordset")
rscity.open "select * from city where 區(qū)號='" & rs("城市")&"'",conn,1,1
If Not rscity.eof then%>
城市:<%=rscity("城市")%>
<%end if
rscity.close
set rscity=nothing
%></td>
<td width="110" bgcolor="#DFEAF2">
<%set rslb=server.CreateObject("adodb.recordset")
rslb.open "select * from leibie where 類別編號=" & rs("類別"),conn,1,1
If Not rslb.eof then%>
類別:<%=rslb("類別名")%>
<%end if
rslb.close
set rslb=nothing
%>
</td>
<td width="140">推薦指數(shù):<img border="0" src="images/level<%=rs("推薦指數(shù)")%>.gif"></td>
<td width="130" bgcolor="#DFEAF2" align="center"><%=rs("日期")%> </td>
<td width="140" align="center">
<%if rs("審核")=-1 then
response.write"已審"
else
response.write"<font color=red>未審</font>"
end if%><%if rs("推薦")=-1 then response.write"<font color=red>【薦】</font>" end if%>|<a href="admin_zxedit.asp?id=<%=rs("編號")%>"><font color="#0000FF">修</font></a><% if trim(request("x"))="dell" then%>|<a href="?order=<%=order%>&xdel=del&id=<%=rs("編號")%>"><font color=red>刪</font></a><% end if%>
</td>
</tr>
<tr>
<td colspan="6" height="30">介紹:<%=rs("介紹")%></td>
</tr>
<tr>
<td colspan="3" height="30" bgcolor="#DFEAF2">地址:<%=rs("地址")%></td>
<td colspan="3">公交:<%=rs("公交")%></td>
</tr>
<tr>
<td height="30" colspan="3">網(wǎng)站:<%=rs("網(wǎng)站")%></td>
<td colspan="3" bgcolor="#DFEAF2">電話:<%=rs("電話")%></td>
</tr>
</table><hr color="#000000"></td>
</tr>
<%
RowCount = RowCount - 1
rs.MoveNext
Loop
end if%>
</table>
</td>
</tr>
</table>
<% rs.close:conn.close
set rs=nothing:set conn=nothing
%>
</body>
</html>
?? 快捷鍵說明
復(fù)制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -