⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 article_main.asp

📁 SK信息采集2.0功能介绍: 1.可针对任何静态网页,动态网页进行采集。包括htm,html,shtml,ASP,ASPX,JSP,PHP等。 2.增加自定文件采集.用户可采集网页中的所有文件.
💻 ASP
📖 第 1 页 / 共 3 页
字号:
<%@LANGUAGE="VBSCRIPT" CODEPAGE="936"%>
<%Option Explicit%>
<!--#include file="../../Conn.asp"-->
<!--#include file="../../SysCls/KS_CommonCls.asp"-->
<!--#include file="../Inc/Session.asp"-->
<%
'===================================================================================================================
'软件名称:科汛网站管理系统
'当前版本:科汛网站管理系统 V2.2 SP2 Free
'Copyright (C) 2006-2008 Kesion.Com  All rights reserved.
'产品咨询QQ:9537636,41904294
'技术支持QQ:111394,54004407 
'程序版权:科汛网络
'程序开发:科汛网络开发组(总策划:林文仲)
'E-Mail  :kesioncms@hotmail.com webmaster@kesion.com
'官方网站:http://www.kesion.com  
'演示站点:http://test.kesion.com 
'郑重声明:
'    ①、免费版本请在程序首页保留版权信息,并做上本站LOGO友情连接,商业版本无此要求;
'    ②、任何个人或组织不得在授权允许的情况下删除、修改、拷贝本软件及其他副本上一切关于版权的信息;
'    ③、科汛网络保留此软件的法律追究权利
'===================================================================================================================
Dim KSCls
Set KSCls = New Article_Main
KSCls.Execute()
Set KSCls = Nothing

Class Article_Main
        Private KSCMS
		'=====================================声明本页面全局变量==============================================================
        Private ID, I, totalPut, CurrentPage, ArticleSql, ArticleRS, DisplayMode
		Private FolderSql, FolderRS, ArticleTid, ParentID, FolderName, CreateDate, TempStr
		Private KeyWord, SearchType, StartDate, EndDate, VerificTF, ParentRs, SearchParam
		Private MaxPerPage, ShowThumbsTF
		
		Private T, TitleStr, VerificStr, ShortName, Subtitle
		Private TypeStr, CreateDateStr, CreaterStr, AttributeStr, ViewStr
		'======================================================================================================================

		Private Sub Class_Initialize()
		  Set KSCMS=New CommonCls
		End Sub
        Private Sub Class_Terminate()
		 Call KSCMS.CloseConn()
		 Set KSCMS=Nothing
		End Sub
		'主体部分
		Public Sub Execute()
		'收集搜索参数
		KeyWord = KSCMS.G("KeyWord")
		SearchType = KSCMS.G("SearchType")
		StartDate = KSCMS.G("StartDate")
		EndDate = KSCMS.G("EndDate")
		VerificTF = KSCMS.G("VerificTF") '审核标志
		
		'搜索参数集合
		SearchParam = "KeyWord=" & KeyWord & "&SearchType=" & SearchType & "&StartDate=" & StartDate & "&EndDate=" & EndDate & "&VerificTF=" & VerificTF
		
		'取得显示方式
		DisplayMode = KSCMS.G("DisplayMode")
		If DisplayMode = "" Then
		  DisplayMode = KSCMS.GetConfig("DisplayMode")
		End If
		ID = Trim(KSCMS.G("ID"))
		If ID = "" Then ID = "0"
		
		If ID = "0" Then
		 TempStr = "频道"
		Else
		 TempStr = "栏目"
		End If
		
		MaxPerPage = KSCMS.GetConfig("MaxPerPage")     '取得每页显示数量
		ShowThumbsTF = KSCMS.GetChannelConfig(1, "ShowThumbsTF") '取得鼠标经过文章是否显示缩略图标志
		
		If KSCMS.G("page") <> "" Then
			  CurrentPage = KSCMS.ChkClng(KSCMS.G("page"))
		Else
			  CurrentPage = 1
		End If
		If ID <> "0" Then
		  Set ParentRs = conn.Execute("Select TN From KS_Class  Where ID='" & ID & "'")
		  ParentID = ParentRs(0)
		  ParentRs.Close
		  Set ParentRs = Nothing
		End If
		With Response
		.Write "<html>"
		.Write "<head>"
		.Write "<meta http-equiv=""Content-Type"" content=""text/html; charset=gb2312"">"
		.Write "<title>文章管理主页面</title>"
		.Write "<link href=""../Inc/Admin_Style.CSS"" rel=""stylesheet"" type=""text/css"">"
		.Write "<script language=""JavaScript"">"
		.Write " var DomainStr='" & KSCMS.GetDomain & "';"
		.Write " var ClassID='" & ID & "';                //目录ID" & vbCrLf
		.Write " var ParentID='" & ParentID & "';         //父目录ID" & vbCrLf
		.Write " var Page='" & CurrentPage & "';          //当前页码" & vbCrLf
		.Write " var KeyWord='" & KeyWord & "';           //关键字" & vbCrLf
		.Write " var SearchParam='" & SearchParam & "';   //搜索参数集合" & vbCrLf
		.Write " var CutCopyPower='" & KSCMS.ReturnPowerResult(1, "KMA10017") & "';   //剪切复制的权限 " & vbCrLf
		.Write " var TempStr='" & TempStr & "';" & vbCrLf
		.Write " var ShowDetail='" & KSCMS.GetConfig("ShowDetail") & "';  //鼠标点击左窗口是否显示详细信息 1显示,0不显示" & vbCrLf
		.Write " var DisplayMode='" & DisplayMode & "';  //显示方式" & vbCrLf
		.Write "</script>" & vbCrLf
		.Write "<script language=""JavaScript"" src=""../JS/Common.js""></script>" & vbCrLf
		.Write "<script language=""JavaScript"" src=""../JS/ContextMenu.js""></script>"
		.Write "<script language=""JavaScript"" src=""../JS/SelectElement.js""></script>"
		.Write "<script language=""JavaScript"" src=""../Common/ArticleFunction.JS""></script>"
		.Write "</head>"
		.Write "<body scroll=no topmargin=""0"" leftmargin=""0"" onclick=""SendToLeftFrame();SelectElement();"" onkeydown=""GetKeyDown();"" onselectstart=""return false;"">"
		.Write "<table width=""100%"" border=""0"" cellspacing=""0"" cellpadding=""0"" class=""sortbutton"">"
		.Write "  <tr>"
		.Write "    <td height=""23"">"
			  If KeyWord = "" Then
				 .Write "<input class=""buttonstyle"" name=""CreateFolder""  title=""添加" & TempStr & """ type=""button"" value=""添加" & TempStr & """ onclick=""CreateFolder();"" >"
				 .Write "<input class=""buttonstyle"" name=""EditFolder"" title=""编辑" & TempStr & """ type=""button"" value=""编辑" & TempStr & """ onclick=""Edit('Folder');"" >"
				 .Write "<input class=""buttonstyle"" name=""channeldel"" title=""删除" & TempStr & """ type=""button"" value=""删除" & TempStr & """ onclick=""Delete('Folder')"">"
				 .Write "<input class=""buttonstyle"" title=""搜索小助理"" type=""button"" name=""Submit"" value=""搜索助理"" onClick=""parent.frames['LeftFrame'].initializeSearch('Article')"">"
				 .Write "<input class=""buttonstyle""  name=""CommentButton"" title=""评论管理"" type=""button"" value=""评论管理"" onclick=""Comment();"" >"
				If ID = "0" Then
				 .Write "<input class=""buttonstyle"" Disabled name=""AddTojs"" title=""加入自由JS"" type=""button"" value=""加入JS"" onclick=""AddToJS();"" >"
				 .Write "<input class=""buttonstyle"" Disabled name=""AddToSpecial"" title=""加入专题"" type=""button"" value=""加入专题"" onClick=""AddToSpecial();"" >"
				 .Write "<input class=""buttonstyle"" Disabled name=""Verific"" title=""批量审核文章"" type=""button"" value=""批量审核"" onclick=""Verific(1);"" >"
				 .Write "<input class=""buttonstyle"" Disabled name=""Verific"" title=""批量取消文章审核"" type=""button"" value=""取消审核"" onclick=""Verific(0);"" >"
				 .Write "<input class=""buttonstyle"" Disabled name=""NVerificButton"" title=""列出当前栏目未审核的文章"" type=""button"" value=""未审文章"" onclick=""ViewByVerific(0);"" >"
				 .Write "<input class=""buttonstyle"" Disabled name=""VerificButton"" title=""列出当前栏目已审核的文章"" type=""button"" value=""已审文章"" onclick=""ViewByVerific(1);"" >"
				 .Write "<input class=""buttonstyle"" Disabled name=""back"" title=""返回到上一级栏目"" type=""button"" value=""回上一级"" onclick=""ChangeUp();event.cancelBubble=true;"" >"
		
			   Else
				 .Write "<input class=""buttonstyle"" name=""AddTojs"" title=""加入自由JS"" type=""button"" value=""加入JS"" onclick=""AddToJS();"" >"
				 .Write "<input class=""buttonstyle"" name=""AddToSpecial"" title=""加入专题"" type=""button"" value=""加入专题"" onClick=""AddToSpecial();"" >"
				 .Write "<input class=""buttonstyle"" name=""Verific"" title=""批量审核文章"" type=""button"" value=""批量审核"" onclick=""Verific(1);"" >"
				 .Write "<input class=""buttonstyle"" name=""Verific"" title=""批量取消文章审核"" type=""button"" value=""取消审核"" onclick=""Verific(0);"" >"
				 .Write "<input class=""buttonstyle"" name=""NVerificButton"" title=""列出当前栏目未审核的文章"" type=""button"" value=""未审文章"" onclick=""ViewByVerific(0);"" >"
				 .Write "<input class=""buttonstyle"" name=""VerificButton"" title=""列出当前栏目已审核的文章"" type=""button"" value=""已审文章"" onclick=""ViewByVerific(1);"" >"
				 .Write "<input class=""buttonstyle"" name=""back"" title=""返回到上一级栏目"" type=""button"" value=""回上一级"" onclick=""ChangeUp();event.cancelBubble=true;"" >"
			   End If
			  Else
			   .Write ("<img src='../Images/home.gif' align='absmiddle'><span style='cursor:hand' onclick='location.href=""Article_Main.asp"";parent.parent.frames[""BottomFrame""].location=""../Split.asp?ButtonSymbol=Disabled&OpStr=文章管理 >> <font color=red>浏览频道</font>"";'>文章首页</span>")
			   .Write (">>> 搜索结果: ")
				 If StartDate <> "" And EndDate <> "" Then
					.Write ("文章更新日期在 <font color=red>" & StartDate & "</font> 至 <font color=red> " & EndDate & "</font>&nbsp;&nbsp;&nbsp;&nbsp;")
				 End If
			   Select Case SearchType
				Case 0
				   .Write ("标题中含有 <font color=red>" & KeyWord & "</font> 的文章")
				Case 1
				  .Write ("内容中含有 <font color=red>" & KeyWord & "</font> 的文章")
				Case 2
				  .Write ("关键字中含有<font color=red>" & KeyWord & "</font> 的文章")
				Case 3
				  .Write ("作者含有<font color=red>" & KeyWord & "</font> 的文章")
				Case 4
				  .Write ("录入者含有<font color=red>" & KeyWord & "</font> 的文章")
			  End Select
			  End If
			  
			 .Write (" <span  style=""border:1px solid #000000; position:absolute;top:4;right:8; overflow:hidden;"" >")
			 .Write (" <select style=""margin:-2px;"" OnChange=""ChangeDisplayMode(options[selectedIndex].value);"">")
		
			  If DisplayMode = 1 Then
				 .Write (" <option selected value=""Article_Main.asp?DisplayMode=1&ID=" & ID & "&" & SearchParam & """>&nbsp;&nbsp;图 标</option>")
			  Else
				 .Write (" <option value=""Article_Main.asp?DisplayMode=1&ID=" & ID & "&" & SearchParam & """>&nbsp;&nbsp;图 标</option>")
			  End If
			  If DisplayMode = 2 Then
				.Write (" <option selected value=""Article_Main.asp?DisplayMode=2&ID=" & ID & "&" & SearchParam & """>&nbsp;&nbsp;平 铺</option>")
			  Else
				.Write (" <option value=""Article_Main.asp?DisplayMode=2&ID=" & ID & "&" & SearchParam & """>&nbsp;&nbsp;平 铺</option>")
			  End If
			  If DisplayMode = 3 Then
				.Write (" <option selected value=""Article_Main.asp?DisplayMode=3&ID=" & ID & "&" & SearchParam & """>&nbsp;&nbsp;列 表</option>")
			  Else
				.Write (" <option value=""Article_Main.asp?DisplayMode=3&ID=" & ID & "&" & SearchParam & """>&nbsp;&nbsp;列 表</option>")
			  End If
			  If DisplayMode = 4 Then
				.Write (" <option selected value=""Article_Main.asp?DisplayMode=4&ID=" & ID & "&" & SearchParam & """>&nbsp;&nbsp;详细列表</option>")
			  Else
				.Write (" <option value=""Article_Main.asp?DisplayMode=4&ID=" & ID & "&" & SearchParam & """>&nbsp;&nbsp;详细列表</option>")
			  End If
		  
			.Write ("  </span> </td>")
			.Write ("</tr>")
			.Write ("</table>")
		
		 .Write ("<div style="" height:95%; overflow: auto; width:100%"" align=""center"">")
		   Dim Param
			Param = " Where DelTF=0"
		   If KeyWord <> "" Or VerificTF <> "" Then
			  FolderSql = "select OrderID,ID,TN,FolderName,FolderName,Creater,CreateDate,ChannelID,TJ,TJ,TJ,TJ,Tj,TJ,FolderName from KS_Class where 1=0"
			  If VerificTF <> "" Then
			   Param = Param & " And Verific=" & VerificTF & " And Tid='" & ID & "'"
			  Else
				Select Case SearchType
				  Case 0
					 Param = Param & " And (Title like '%" & KeyWord & "%' OR SubTitle like '%" & KeyWord & "')"
				  Case 1
					 Param = Param & " And ArticleContent like '%" & KeyWord & "%'"
				  Case 2
					 Param = Param & " And KeyWords like '%" & KeyWord & "%'"
				  Case 3
					 Param = Param & " And Author like '%" & KeyWord & "%'"
				  Case 4
					 Param = Param & " And ArticleInput like'%" & KeyWord & "%'"
				End Select
				If StartDate <> "" And EndDate <> "" Then
					If CInt(Application("DataBaseType")) = 1 Then         'Sql
					   Param = Param & " And (AddDate>= '" & StartDate & "' And AddDate<= '" & DateAdd("d", 1, EndDate) & "')"
					Else                                                 'Access
					   Param = Param & " And (AddDate>=#" & StartDate & "# And AddDate<=#" & DateAdd("d", 1, EndDate) & "#)"
					End If
				End If
			End If
		  Else
			 FolderSql = "Select OrderID,ID,TN,FolderName,FolderName,Creater,CreateDate,ChannelID,TJ,TJ,TJ,TJ,Tj,TJ,FolderName from KS_Class where ChannelID=1 And tn='" & ID & "'"
			 Param = Param & " And Tid='" & ID & "'"
		  End If
		ArticleSql = FolderSql & " Union All Select OrderID,NewsID,Tid,Title,SubTitle,ArticleInput,AddDate,PicNews,Verific,Recommend,Popular,Strip,Rolls,Slide,PicUrl From KS_Article" & Param & " Order BY OrderID,CreateDate Desc"
		Set ArticleRS = Server.CreateObject("AdoDb.RecordSet")
		 ArticleRS.Open ArticleSql, conn, 1, 1
				 If ArticleRS.EOF And ArticleRS.BOF Then
				 Else
					totalPut = ArticleRS.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
		
							If CurrentPage = 1 Then
								Call showContent(DisplayMode)
							Else
								If (CurrentPage - 1) * MaxPerPage < totalPut Then
									ArticleRS.Move (CurrentPage - 1) * MaxPerPage
									
									Call showContent(DisplayMode)
								Else

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -