?? admin_article.asp
字號:
<!--#include file="conn.asp"-->
<!--#include file="../unhtml.asp"-->
<!--#include file="../ubb.asp"-->
<%
if session("login")<>"yes" then
response.write "<script language=JavaScript>" & chr(13) & "alert('您還未登錄或者超時,請重登錄!');"&"window.location.href = '../'"&" </script>"
response.end
end if
%>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<link rel="stylesheet" href="../css.css" type="text/css">
<title>建站咨訊管理</title>
<base target="_self">
<style type="text/css">
<!--
.style1 {
color: #9933FF;
font-weight: bold;
}
-->
</style>
</head>
<body bgcolor="#CAD7F7" vlink="#000000">
<table border="0" width="100%" cellspacing="0" cellpadding="4" bgcolor="#FFFFFF" style="border:1px solid #000000; " height="209">
<tr bgcolor="#99CCFF">
<td width="709" height="25" colspan="5">
<p align="center" class="style1"><font size="2">站內文章管理</font></td>
</tr>
<tr bgcolor="#9CCFFF">
<td height="26" align="center" width="430">
<p align="left"><b><a href="admin_add_article.asp">添加文章</a></b></td>
<td height="26" align="center" width="67">
<b>分類顯示:</b></td>
<td height="26" align="center" width="60">
<a href="admin_article.asp?class=1">新聞動態</a></td>
<td height="26" align="center" width="60">
<a href="admin_article.asp?class=2">求職技巧</a></td>
<td height="26" align="center" width="60">
<a href="admin_article.asp">混合顯示</a></td>
</tr>
<tr bgcolor="#99CCFF">
<td height="100%" align="center" width="709" colspan="5">
<%
if request("class")="1" then
sql="select * from article where class=1 order by id desc"
else
if request("class")="2" then
sql="select * from article where class=2 order by id desc"
else
sql="select * from article order by id desc"
end if
end if
rs.open sql,conn,1,1
if rs.recordcount=0 then
response.write "暫無文章!"
else
rs.pagesize=20
if request("action")="n" then
session("page")=session("page")+1
else
if request("action")="p" then
session("page")=session("page")-1
else
if request("action")="f" then
session("page")=1
else
if request("action")="l" then
session("page")=rs.pagecount
else
if isnumeric(request("page1"))=true then
session("page")=clng(request("page1"))
else
session("page")=1
end if
end if
end if
end if
end if
if session("page")>rs.pagecount then session("page")=rs.pagecount
if session("page")<1 then session("page")=1
%>
<table border="0" width="650" cellspacing="0" cellpadding="0" height="25">
<tr>
<td width="104">
共有文章<font color="#FF0000"><%=rs.recordcount%></font>篇</td>
<td width="112">
<p align="center">當前頁碼:<font color="#FF0000"><%=session("page")%></font>/<%=rs.pagecount%></td>
<td width="248">
<p align="center">< <a href="admin_article.asp?action=f&class=<%=request("class")%>">
首頁</a>
<a href="admin_article.asp?action=p&class=<%=request("class")%>">上一頁</a>
<a href="admin_article.asp?action=n&class=<%=request("class")%>">下一頁</a>
<a href="admin_article.asp?action=l&class=<%=request("class")%>">尾頁</a> ></td>
<td width="186">
<form method="POST" action="admin_article.asp?class=<%=request("class")%>">
<p align="center">跳轉到
<input type="text" name="page1" size="5" style="border: 1px solid #000000">
頁
<input type="submit" value="提交" name="B1"></p>
</form>
</td>
</tr>
</table> </td>
</tr>
<tr bgcolor="#99CCFF">
<td width="709" height="100%" colspan="5" valign="top">
<table border="0" width="709" cellspacing="0" cellpadding="0" height="24">
<tr>
<td style="border-bottom: 1px dotted #000000; padding-left: 4px; padding-right: 4px; padding-top: 1px; padding-bottom: 1px" width="65" height="25" bgcolor="#E5E5E5">
<p align="center"><b>編號</b></td>
<td style="border-bottom: 1px dotted #000000; padding-left: 4px; padding-right: 4px; padding-top: 1px; padding-bottom: 1px" width="262" height="25" bgcolor="#FFFFFF">
<p align="center"><b>標題</b></td>
<td style="border-bottom: 1px dotted #000000; padding-left: 4px; padding-right: 4px; padding-top: 1px; padding-bottom: 1px" width="85" height="25" bgcolor="#E5E5E5">
<p align="center"><b>類別</b></td>
<td style="border-bottom: 1px dotted #000000; padding-left: 4px; padding-right: 4px; padding-top: 1px; padding-bottom: 1px" width="160" height="25" bgcolor="#FFFFFF">
<p align="center"><b>添加時間</b></td>
<td style="border-bottom: 1px dotted #000000; padding-left: 4px; padding-right: 4px; padding-top: 1px; padding-bottom: 1px" width="90" align="center" height="25" colspan="3" bgcolor="#E5E5E5">
<b>操作</b></td>
</tr>
<%
rs.absolutepage=session("page")
for ii=1 to rs.pagesize
%>
<tr>
<td style="border-bottom: 1px dotted #000000; padding-left: 4px; padding-right: 4px; padding-top: 1px; padding-bottom: 1px" width="65" bgcolor="#E5E5E5" height="25">
<p align="center"> <%=rs("id")%></td>
<td style="border-bottom: 1px dotted #000000; padding-left: 4px; padding-right: 4px; padding-top: 1px; padding-bottom: 1px" width="262" height="25">
<a target="_blank" href="../show_article.asp?id=<%=rs("id")%>"><%=unhtml(rs("title"))%></a></td>
<td style="border-bottom: 1px dotted #000000; padding-left: 4px; padding-right: 4px; padding-top: 1px; padding-bottom: 1px" width="85" height="25" bgcolor="#E5E5E5">
<p align="center"><%
if rs("class")=1 then response.write "新聞動態"
if rs("class")=2 then response.write "求職技巧"
%></td>
<td style="border-bottom: 1px dotted #000000; padding-left: 4px; padding-right: 4px; padding-top: 1px; padding-bottom: 1px" width="160" height="25">
<p align="center"> <%=rs("addtime")%></td>
<td style="border-bottom: 1px dotted #000000; padding-left: 4px; padding-right: 4px; padding-top: 1px; padding-bottom: 1px" width="30" align="center" height="25" bgcolor="#E5E5E5">
<a target="_blank" href="../show_article.asp?id=<%=rs("id")%>">
查看</a></td>
<td style="border-bottom: 1px dotted #000000; padding-left: 4px; padding-right: 4px; padding-top: 1px; padding-bottom: 1px" width="30" align="center" height="25" bgcolor="#E5E5E5">
<a href="admin_up_article.asp?id=<%=rs("id")%>">修改</a></td>
<td style="border-bottom: 1px dotted #000000; padding-left: 4px; padding-right: 4px; padding-top: 1px; padding-bottom: 1px" width="30" align="center" height="25" bgcolor="#E5E5E5">
<a onclick="{if(confirm('警告:此操作將刪除文章〈<%=rs("title")%>〉!繼續嗎?')){return true;}return false;}" href="del_article.asp?id=<%=rs("id")%>"><span style="text-decoration: none">刪除</a></td>
</tr>
<%
rs.movenext
if rs.eof then exit for
next
%>
</table> </td>
</tr>
<tr bgcolor="#99CCFF">
<td width="709" height="100%" colspan="5" align="center">
<table border="0" width="650" cellspacing="0" cellpadding="0" height="25">
<tr>
<td width="104">
共有文章<font color="#FF0000"><%=rs.recordcount%></font>篇</td>
<td width="112">
<p align="center">當前頁碼:<font color="#FF0000"><%=session("page")%></font>/<%=rs.pagecount%></td>
<td width="248">
<p align="center">< <a href="admin_article.asp?action=f&class=<%=request("class")%>">
首頁</a>
<a href="admin_article.asp?action=p&class=<%=request("class")%>">上一頁</a>
<a href="admin_article.asp?action=n&class=<%=request("class")%>">下一頁</a>
<a href="admin_article.asp?action=l&class=<%=request("class")%>">尾頁</a> ></td>
<td width="186">
<form method="POST" action="admin_article.asp?class=<%=request("class")%>">
<p align="center">跳轉到
<input type="text" name="page1" size="5" style="border: 1px solid #000000">
頁
<input type="submit" value="提交" name="B2"></p>
</form>
</td>
</tr>
</table> </td>
</tr>
</table>
<%
rs.close
set rs=nothing
set conn=nothing
end if
%>
</body>
</html>
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -