?? newslist.asp
字號:
?<%@LANGUAGE="VBSCRIPT" CODEPAGE="65001"%>
<%
'┌┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┐
'┊ ┊
'┊ 互連在線企業網站管理系統(NWEB) ┊
'┊ ┊
' 版權所有 csys.com.cn
'
' 程序制作 互連在線工作室
' Q Q:61128110
'
' 相關網址 [產品介紹]http://www.csys.com.cn
' [支持論壇]http://www.csys.com.cn/bbs
'
' 演示網址 http://www.csys.com.cn
'┊ ┊
'└┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┘
%>
<% Option Explicit %>
<HTML xmlns="http://www.w3.org/1999/xhtml">
<HEAD>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=utf-8" />
<META NAME="copyright" CONTENT="Copyright 2004-2008 - csys.com.cn-STUDIO" />
<META NAME="Author" CONTENT="互連在線網絡技術工作室,www.csys.com.cn" />
<META NAME="Keywords" CONTENT="" />
<META NAME="Description" CONTENT="" />
<TITLE>新聞列表</TITLE>
<link rel="stylesheet" href="Images/CssAdmin.css">
<script language="javascript" src="../Script/Admin.js"></script>
</HEAD>
<!--#include file="../Include/Const.asp" -->
<!--#include file="../Include/ConnSiteData.asp" -->
<!--#include file="CheckAdmin.asp"-->
<%
if Instr(session("AdminPurview"),"|22,")=0 then
response.write ("<font color='red')>你不具有該管理模塊的操作權限,請返回!</font>")
response.end
end if
'========判斷是否具有管理權限
%>
<BODY>
<%
dim Result,StartDate,EndDate,Keyword,SortID,SortPath
Result=request.QueryString("Result")
StartDate=request.QueryString("StartDate")
EndDate=request.QueryString("EndDate")
Keyword=request.QueryString("Keyword")
SortID=request.QueryString("SortID")
SortPath=request.QueryString("SortPath")
function PlaceFlag()
if Result="Search" then
Response.Write "新聞:列表 -> 檢索 -> 添加時間[<font color='red'>"&StartDate&"至"&EndDate&"</font>],關鍵字[<font color='red'>"&Keyword&"</font>]"
else
if SortPath<>"" then
Response.Write "新聞:列表 -> <a href='NewsList.asp'>全部</a>"
TextPath(SortID)
else
Response.Write "新聞:列表 -> 全部"
end if
end if
end function
%>
<table width="100%" border="0" cellpadding="3" cellspacing="1" bgcolor="#6298E1">
<tr>
<td height="24" nowrap><font color="#FFFFFF"><img src="Images/Explain.gif" width="18" height="18" border="0" align="absmiddle"> <strong>新聞檢索及分類查看:添加,修改,刪除新聞信息</strong></font></td>
</tr>
<tr>
<td height="36" align="center" nowrap bgcolor="#EBF2F9"><table width="100%" border="0" cellspacing="0">
<tr>
<form name="formSearch" method="post" action="Search.asp?Result=News">
<td nowrap> 新聞檢索:從
<script language=javascript>
var myDate=new dateSelector();
myDate.year--;
myDate.date;
myDate.inputName='start_date'; //注意這里設置輸入框的name,同一頁中日期輸入框,不能出現重復的name。
myDate.display();
</script>
到
<script language=javascript>
myDate.year++;
myDate.inputName='end_date'; //注意這里設置輸入框的name,同一頁中的日期輸入框,不能出現重復的name。
myDate.display();
</script>
關鍵字:<input name="Keyword" type="text" class="textfield" value="<%=Keyword%>" size="18">
<input name="submitSearch" type="submit" class="button" value="檢索">
</td>
</form>
<td align="right" nowrap>查看:<a href="NewsList.asp" onClick='changeAdminFlag("新聞列表")'>全部新聞</a><font color="#0000FF"> | </font><a href="NewsSort.asp" onClick='changeAdminFlag("選擇查看分類")'>其他類別新聞</a></td>
</tr>
</table> </td>
</tr>
</table>
<table width="100%" border="0" cellspacing="1" cellpadding="0">
<tr>
<td height="30"><%PlaceFlag()%></td>
</tr>
</table>
<table width="100%" border="0" cellpadding="3" cellspacing="1" bgcolor="#6298E1">
<form action="DelContent.asp?Result=News" method="post" name="formDel" >
<tr>
<td width="30" nowrap bgcolor="#8DB5E9"><font color="#FFFFFF"><strong>ID</strong></font></td>
<td width="28" height="24" nowrap bgcolor="#8DB5E9"><font color="#FFFFFF"><strong>發布</strong></font></td>
<td nowrap bgcolor="#8DB5E9"><font color="#FFFFFF"><strong>新聞標題</strong>(指向顯示所屬類別)</font></td>
<td width="28" nowrap bgcolor="#8DB5E9"><font color="#FFFFFF"><strong>標記</strong></font></td>
<td width="76" nowrap bgcolor="#8DB5E9"><strong><font color="#FFFFFF">查看組別</font></strong></td>
<td width="76" nowrap bgcolor="#8DB5E9"><strong><font color="#FFFFFF">新聞來源</font></strong></td>
<td width="120" nowrap bgcolor="#8DB5E9"><strong><font color="#FFFFFF">發布時間</font></strong></td>
<td width="52" nowrap bgcolor="#8DB5E9"><strong><font color="#FFFFFF">查看次數</font></strong></td>
<td colspan="2" width="76" nowrap bgcolor="#8DB5E9"><strong><font color="#FFFFFF">操作</font></strong>
<input onClick="CheckAll(this.form)" name="buttonAllSelect" type="button" class="button" id="submitAllSearch" value="全" style="HEIGHT: 18px;WIDTH: 16px;">
<input onClick="CheckOthers(this.form)" name="buttonOtherSelect" type="button" class="button" id="submitOtherSelect" value="反" style="HEIGHT: 18px;WIDTH: 16px;"> </td>
</tr>
<% NewsList() %>
</form>
</table>
</BODY>
</HTML>
<%
'-----------------------------------------------------------
function NewsList()
dim idCount'記錄總數
dim pages'每頁條數
pages=20
dim pagec'總頁數
dim page'頁碼
page=clng(request("Page"))
dim pagenc'每頁顯示的分頁頁碼數量=pagenc*2+1
pagenc=2
dim pagenmax'每頁顯示的分頁的最大頁碼
dim pagenmin'每頁顯示的分頁的最小頁碼
dim datafrom'數據表名
datafrom="Csys_News"
dim datawhere'數據條件
if Result="Search" then
datawhere="where ( NewsName like '%" & Keyword &_
"%') and AddTime >= #" & StartDate & " # and AddTime <= #" & EndDate & "#"
else
if SortPath<>"" then'是否查看的分類產品
datawhere="where Instr(SortPath,'"&SortPath&"')>0 "
else
datawhere=""
end if
end if
dim sqlid'本頁需要用到的id
dim Myself,PATH_INFO,QUERY_STRING'本頁地址和參數
PATH_INFO = request.servervariables("PATH_INFO")
QUERY_STRING = request.ServerVariables("QUERY_STRING")'
if QUERY_STRING = "" or Instr(PATH_INFO & "?" & QUERY_STRING,"Page=")=0 then
Myself = PATH_INFO & "?"
else
Myself = Left(PATH_INFO & "?" & QUERY_STRING,Instr(PATH_INFO & "?" & QUERY_STRING,"Page=")-1)
end if
dim taxis'排序的語句 asc,desc
taxis="order by id desc"
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -