📄 sk_getrc.asp
字号:
<%
option explicit
response.buffer=true
'================================================================================================
' 软件名称:清风信息自动采集生成系统
' 当前版本:CJ 1.0
' 更新日期:2008-7-18
' 程序版权:龙心数据
' 程序开发:龙心数据开发组
' 演示站点:http://cj.iising.com
' 官方网站:http://www.iising.com QQ:24387481 电话:13719316070
' 郑重声明:
' ①、没有版权,你爱抄抄,爱搬搬,偶看不见!
' ②、不要用黑与白来衡量你我之间的距离,更不要让生活磨灭我们的个性!
' ③、欢迎定做各种信息采集功能系统。
'================================================================================================
%>
<!--#include file="inc/setup.asp"-->
<!--#include file="inc/cj_cls.asp"-->
<!--#include file="SK_Session.asp"-->
<%
'--自定义变量
Dim Rs,Sql,FoundErr
Dim SqlItem,RsItem
Dim ItemID,ItemName,WebName,WebUrl,ChannelID,ChannelDir,ClassID,SpecialID,selEncoding,ItemDemo,LoginType,LoginUrl,LoginPostUrl,LoginUser,LoginPass,LoginFalse,Colleclx,ListStr,radio,LPsString,LPoString,ListPaingStr2 ,ListPaingID1,ListPaingID2,ListPaingStr3,Passed,SaveFiles,CollecOrder,ListPaingType,Flag,ListUrl,ItemCollecDate,LsString,LoString,HsString,HoString,imhstr,imostr,x_tp,Script_Iframe,Script_Object,Script_Script,Script_Div,Script_Class,Script_Table,Script_Tr,Script_Span,Script_Img,Script_Font,Script_A,Script_Html,Script_Td,Stars,ReadPoint,radioid,Hits,SaveFileUrl,HttpUrlStr,FilterType,CollecNewsNum,Timing,picpath,strReplace,IncludePic,UploadFiles,Downlist_s,Downlist_o,DownUrl_s,DownUrl_o,DownNewType,DownNewlist_s,DownNewlist_o,DownNewUrl_s,DownNewUrl_o,Zds_007
Dim Thumb_WaterMark,Thumbs_Create,DownUrls
Dim TsString,ToString,CsString,CoString,DateType,DsString,DoString,UpDateTime,AuthorType,AsString,AoString,AuthorStr,CopyFromType,FsString,FoString,CopyFromStr,KeyType,KsString,KoString,KeyStr,NewsPaingType,NPsString,NPoString,NewsPaingStr,NewsPaingHtml,Author,NewsUrlPaing_s,NewsUrlPaing_o
Dim PicUrls,ListTypeCode,ListTypeUrlCode,TypeUrlArray,TypeNewsUrl,NewsTypeCode
Dim CopyFrom,Key,SqlF,RSF,Arr_Filters,strInstallDir,strChannelDir
Dim photourls,photourlo,PhotoPaingType,PhotoType_s,PhotoType_o,PhotoLurl_s,PhotoLurl_o,Phototypefy_s,Phototypefy_o,Phototypefyurl_s,Phototypefyurl_o,Phototypeurl_s,Phototypeurl_o,Title,Content
dim UpDateType
dim temp_Fields
Dim tClass,tSpecial,CurrentPage,MaxPerPage,Allpage,ItemNum,iItem,NewsArrayCode,NewsArray,Testi,HttpUrlType,UrlTest,NewsCode,NewsUrl,NewsPaingNext,NewsPaingNext_Code,TypeArray_Url
dim Newsimage,Newsim
Dim i_Channel,i_Class,i_Special,tmpDepth,i,ArrShowLine(20)
Dim ClassName,SpecialName,Item_add,action,action1,ListCode
Dim rs_num
Dim ZdField(999)'--自定义
Colleclx=Skcj.ChkNumeric(Skcj.G("Colleclx"))
Colleclx=7
IF Colleclx=0 then
Response.Write ("模块ID出错!")
Response.End
End if
Response.Write(Trim(Request.Form("DClassID")))
ItemID=Skcj.G("ItemID")
action=Skcj.G("action")
action1=Skcj.G("action1")
Dim CjName : CjName=Skcj.GetItemConfig("CjName",Colleclx)
Dim CJFileName : CJFileName = Skcj.GetItemConfig("FileName",Colleclx)
'----------------------------------------------------------------------------------------------------------------------------
Call Skcj.Show_Top()
If action="edit" Or action1="edit" Or action="s1" And action1<>"add" Or action="s2" And action1<>"add" Then
Response.Write "<table width=""100%"" border=""0"" align=""center"" cellpadding=""0"" cellspacing=""1"" class=""tableBorder"">"
Response.Write "<tr class=""tdbg"">"
Response.Write "<td width=""65"" height=""30"" bgcolor=""#F3F3F3""><strong>管理导航:</strong></td>"
Response.Write "<td height=""30"" bgcolor=""#F3F3F3""> <font color=red><a href=?action=edit&ItemID="& ItemID &">基本设置</a></font> >> <a href=?action=s1&ItemID="& ItemID &">第一步</a> >> <a href=?action=s2&ItemID="& ItemID &">第二步</a> >> <a href=?action=demo&ItemID="& ItemID &">采样测试</a> </td>"
Response.Write "</tr></table>"
End If
Select Case action
Case "config"
Call config'采集基本设置
Case "ClassCj"'批量采集
Call ClassCj
Case "BeginClasscj"'开始批量采集
Call BeginClasscj
Case "add"
Call addnew1()'初步
Case "edit"
Call addnew1()'初步
Case "s1"
Call setup1()
Case "s2"
Call setup2()
Case "demo"
Call demo()
Case "copy"
Call copy()
Case "Del"
Call Del()
Case else
Call Show_Manage()
End Select
Call CloseConnItem()
'=================================
'采集项目管理
'=================================
Sub Show_Manage
Dim MaxPerPage
MaxPerPage=Skcj.GetItemConfig("MaxPerPage",Colleclx)
IF MaxPerPage=0 Then MaxPerPage=10
%>
</head>
<body leftmargin="0" topmargin="0" marginwidth="0" marginheight="0">
<table width="100%" border="0" align="center" cellpadding="0" cellspacing="1" class="tableBorder" >
<tr>
<td height="22" colspan="2" class="title"> <div align="center"><strong>购买详细演示联系QQ:24387481 </strong></div>
</td>
</tr>
</table>
<table width="100%" border="0" align="center" cellpadding="0" cellspacing="1" bgcolor="#cccccc" class="tableBorder">
<form name="myform" method="POST" action="<%= CJFileName %>">
<tr class="tdbg" style="padding: 0px 2px;">
<td width="33" height="22" align="center" bgcolor="#f3f3f3">选择</td>
<td width="188" align="center" bgcolor="#f3f3f3">项目名称</td>
<td width="153" height="22" align="center" bgcolor="#f3f3f3">所属分类</td>
<td width="133" align="center" bgcolor="#f3f3f3">所属专题</td>
<td width="32" align="center" bgcolor="#f3f3f3">状态</td>
<td width="180" height="22" align="center" bgcolor="#f3f3f3">上次采集</td>
<td width="192" height="22" align="center" bgcolor="#f3f3f3">操作</td>
</tr>
<%
If Skcj.G("page")<>"" Then
CurrentPage=Cint(Skcj.G("Page"))
Else
CurrentPage=1
End If
Dim SqlTemp
ClassID=Skcj.ChkNumeric(Skcj.G("DclassID"))
If ClassID=0 Then
SqlTemp=""
Else
SqlTemp=" And ClassID='" &ClassID&"'"
End if
Set RsItem=server.createobject("adodb.recordset")
SqlItem="Select * from Item where Colleclx="& Colleclx &" "& SqlTemp &" order by ItemID DESC"
RsItem.open SqlItem,ConnItem,1,1
If Not RsItem.Eof Then
RsItem.PageSize=MaxPerPage
Allpage=RsItem.PageCount
If Currentpage>Allpage Then Currentpage=1
ItemNum=RsItem.RecordCount
RsItem.MoveFirst
RsItem.AbsolutePage=CurrentPage
iItem=0
Do While Not RsItem.Eof
ItemID=RsItem("ItemID")
ItemName=RsItem("ItemName")
WebName=RsItem("WebName")
ChannelID=RsItem("ChannelID")
ClassID=RsItem("ClassID")
SpecialID=RsItem("SpecialID")
ListStr=RsItem("ListStr")
ListPaingType=RsItem("ListPaingType")
ListPaingStr2=RsItem("ListPaingStr2")
ListPaingID1=RsItem("ListPaingID1")
ListPaingID2=RsItem("ListPaingID2")
ListPaingStr3=RsItem("ListPaingStr3")
Flag=RsItem("Flag")
If ListPaingType=0 Then
ListUrl=ListStr
ElseIf ListPaingType=1 Then
ListUrl=Replace(ListPaingStr2,"{$ID}",CStr(ListPaingID1))
ElseIf ListPaingType=2 Then
If Instr(ListPaingStr3,"|")>0 Then
ListUrl=Left(ListPaingStr3,Instr(ListPaingStr3,"|")-1)
Else
ListUrl=ListPaingStr3
End If
End If
%>
<tr class="tdbg" onMouseOut="this.style.backgroundColor=''" onMouseOver="this.style.backgroundColor='#BFDFFF'" style="padding: 0px 2px; " >
<td width="33" height="22" align="center" style=" border-bottom:#cccccc 1xp solid">
<input type="checkbox" value="<%=ItemID%>" name="ItemID" ></td>
<td width="188" align="center" style=" border-bottom:#cccccc 1xp solid"><a href="<%=ListUrl%>" target="_bank"><%=ItemName%></a></td>
<td width="153" align="center" style=" border-bottom:#cccccc 1xp solid" title="所属频道-<%Call Admin_ShowChannel_Name(ChannelID)%>"><%Call Admin_ShowClass_Name(ChannelID,ClassID)%></td>
<td width="133" align="center" style=" border-bottom:#cccccc 1xp solid"><%Call Admin_ShowSpecial_Name(ChannelID,SpecialID)%></td>
<td width="32" align="center" style=" border-bottom:#cccccc 1xp solid"> <b>
<%If Flag=True Then
Response.write "√"
Else
Response.write "<font color=red>×</font>"
End If
%>
</b> </td>
<td width="180" align="center" style=" border-bottom:#cccccc 1xp solid;">
<%
Set Rs=connItem.execute("Select Top 1 CollecDate From Histroly Where ItemID=" & ItemID & " Order by HistrolyID desc")
If Not Rs.Eof Then
ItemCollecDate=rs("CollecDate")
Else
ItemCollecDate=""
End If
Set Rs=Nothing
If ItemCollecDate<>"" Then
Response.Write "<font color=""#FF0000"">"& ItemCollecDate &"</font>"
Else
Response.Write "尚无记录"
End If
%> </td>
<td width="192" align="center" style=" border-bottom:#cccccc 1xp solid"><a href=<%= CJFileName %>?Action=copy&ItemID=<%=ItemID%>&Colleclx=<%= Colleclx %>>复制</a> <a href=<%= CJFileName %>?Action=edit&ItemID=<%=ItemID%>&Colleclx=<%= Colleclx %>>编辑</a> <a href=Sk_Collection.asp?ItemID=<%=ItemID%>&ItemNum=1&ListNum=1&NewsSuccesNum=0&NewsFalseNum=0&ImagesNumAll=0&NewsNum_i=0>采集</a> <a href=<%= CJFileName %>?action=demo&ItemID=<%=ItemID%>&Colleclx=<%= Colleclx %>>测试</a> <a href=<%= CJFileName %>?Action=Del&ItemID=<%=ItemID%>&Colleclx=<%= Colleclx %> onClick='return confirm("确定要删除此项目吗?请您慎重选择!这将删除该项目的项目信息,历史记录及过滤信息 3 个项目类型数据。");'>删除</a> </td>
</tr>
<%
iItem=iItem+1
If iItem>=MaxPerPage Then Exit Do
RsItem.MoveNext
Loop
%>
<tr class="tdbg">
<td colspan=7 height="30" >
<input name="Action" type="hidden" value="Del">
<input name="chkAll" type="checkbox" id="chkAll" onClick=CheckAll(this.form) value="checkbox" >
全选 </td>
</tr>
<tr class="tdbg">
<td colspan=7 height="30" align=center><input name="Del" type="submit" class="lostfocus" style="cursor: hand;background-color: #cccccc;" value="快速采集">
<input name="Del" type="submit" class="lostfocus" style="cursor: hand;background-color: #cccccc;" onClick='return confirm("确定要删除选中的项目吗?请您慎重选择!这将删除该项目的项目信息,历史记录及过滤信息 3 个项目类型数据。");' value=" 删 除 ">
<input name="Del" type="submit" class="lostfocus" style="cursor: hand;background-color: #cccccc;" onClick='return confirm("您真的要确定要清空所有项目吗?这将彻底格式化采集数据库的所有信息,请您先备份再选择!!!");' value="清空所有记录">
</td>
</tr>
<%Else%>
<tr class="tdbg">
<td colspan='7' class="tdbg" align="center"><br>
系统中暂无采集项目!</td>
</tr>
<%End If
RsItem.Close
Set RsItem=Nothing
%>
</form>
</table>
<table width="100%" border="0" align="center" cellpadding="0" cellspacing="1" class="tableBorder" >
<tr>
<td height="22" colspan="2" class="tdbg">
<%
Response.Write ShowPage(CJFileName,ItemNum,MaxPerPage,True,True," 个项目")
%>
</td>
</tr>
</table>
<%
End Sub
'====================================
'批量采集
'====================================
Sub ClassCj
%>
<table width="97%" border="0" align="center" cellpadding="0" cellspacing="1" class="tableBorder" >
<tr>
<th height="22" colspan="2" class="title"> <div align="center"><b><% =ErrMsg_lx %>分类 管 理</b>
</div></th>
</tr>
<tr>
<td height="22" colspan="2" ><table width="100%" border="0" align="center" cellpadding="0" cellspacing="1" bgcolor="#FFFFFF">
<TR>
<TD width="19%" height=22 align=center bgcolor="#CAD7F7"> 编号
</DIV></TD>
<TD width="66%" height=22 align=center bgcolor="#CAD7F7"> 栏目分类名称</TD>
<TD width="15%" height=22 align=center bgcolor="#CAD7F7"> 操作</TD>
</TR>
<%
Colleclx=Trim(Request("Colleclx"))
select case Colleclx
case 1
Sql="select * from SK_class where ChannelID=1 order by OrderID"
case 3
Sql="select * from SK_class where ChannelID=3 order by OrderID"
case 5
Sql="select * from SK_class where ChannelID=5 order by OrderID"
case 0
Call CloseConnItem
Response.end
end select
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -