<!--#include file="inc/function.asp" -->
<!--#include file="../inc/function.asp" -->

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<TITLE>采集管理 - 采集项目管理 - 126电影程序CMS</TITLE>
<META http-equiv=Content-Type content="text/html; charset=gb2312">
<LINK href="../images/css_body.css" type=text/css rel=stylesheet>
<script src="../images/admin.js" type="text/javascript"></script>
</head>

<body >
<%
dim action
action=Trim(request.QueryString("action"))
Select Case action
Case "Alldc"
 call Alldc()
Case "add"
 call Add()
Case "Add2"
 call Add2()
Case "Add3"
 call Add3()
Case "Add4"
 call Add4()
Case "AddSever"
 Session("ListUrl")=""
 Session("selEncoding")=""
 Session("ListCode")=""
 Session("NewsCode")=""
 call Admin_ShowErr("<li>采集栏目添加成功</li>","admin_collect.asp",1)
Case "Edit"
 call Edit()
Case "Edit2"
 call Edit2()
Case "Edit3"
 call Edit3()
Case "Edit4"
 call Edit4()
Case "EditSever"
 Session("ListUrl")=""
 Session("selEncoding")=""
 Session("ListCode")=""
 Session("NewsCode")=""
 Call AddLog("修改采集栏目",9)
 call Admin_ShowErr("<li>采集栏目修改成功</li>","admin_collect.asp",1)
Case "Del"
 call Del()
case "Delall"
 call Delall()
Case "Copy"
 call Copy()
Case else
 call List()
End Select

sub Alldc()
dim ids:ids=replace(request.Form("id")," ","")
if not isNul(ids) then 
	Set Rs = connc.Execute("Select * From programe where id in ("&ids&")")
	'die "Select * From programe where id in ("&ids&")"
	Do Until Rs.Eof
	 set rst=Server.CreateObject("ADODB.Recordset")
	 sqlt="select * from programe where id in ("&ids&")"
	 Rst.open sqlt,connt,1,3
	 RSt.Addnew
	 RSt("CollectName")=rs("CollectName")
	 RSt("selEncoding")=rs("selEncoding")
	 RSt("WebUrl")=rs("WebUrl")
	 RSt("Harea")=rs("Harea")
	 RSt("Farea")=rs("Farea")
	 RSt("Server")=rs("Server")
	 RSt("ClassID")=rs("ClassID")
	 RSt("ListPaingType")=rs("ListPaingType")
	 RSt("ListPaingStr")=rs("ListPaingStr")
	 RSt("ListPaingStr2")=rs("ListPaingStr2")
	 RSt("ListPaingID1")=rs("ListPaingID1")
	 RSt("ListPaingID2")=rs("ListPaingID2")
	 RSt("ListPaingStr3")=rs("ListPaingStr3")
	 RSt("Script_Iframe")=rs("Script_Iframe")
	 RSt("Script_Object")=rs("Script_Object")
	 RSt("Script_Script")=rs("Script_Script")
	 RSt("Script_Div")=rs("Script_Div")
	 RSt("Script_Class")=rs("Script_Class")
	 RSt("Script_Table")=rs("Script_Table")
	 RSt("Script_Tr")=rs("Script_Tr")
	 RSt("Script_Span")=rs("Script_Span")
	 RSt("Script_Img")=rs("Script_Img")
	 RSt("Script_Font")=rs("Script_Font")
	 RSt("Script_A")=rs("Script_A")
	 RSt("Script_Html")=rs("Script_Html")
	 RSt("Script_Td")=rs("Script_Td")
	 RSt("SaveFiles")=rs("SaveFiles")
	 RSt("CollecOrder")=rs("CollecOrder")
	 RSt("RepeatCollect")=rs("RepeatCollect")
	 RSt("LsString")=rs("LsString")
	 RSt("LoString")=rs("LoString")
	 RSt("HsString")=rs("HsString")
	 RSt("HoString")=rs("HoString")
	 RSt("Htitle")=rs("Htitle")
	 RSt("ListPaingStr3")=rs("ListPaingStr3") 
	 RSt("Ftitle")=rs("Ftitle")
	 RSt("Hname")=rs("Hname")
	 RSt("Fname")=rs("Fname")
	 RSt("Timea1")=rs("Timea1")
	 RSt("Timea2")=rs("Timea2")
	 RSt("Htupian")=rs("Htupian")
	 RSt("Ftupian")=rs("Ftupian")
	 RSt("ClassType")=rs("ClassType")
	 RSt("CollectClass")=rs("CollectClass")
	 RSt("HClass")=rs("HClass")
	 RSt("FClass")=rs("FClass")
	 RSt("RegionType")=rs("RegionType")
	 RSt("CollectRegion")=rs("CollectRegion")
	 RSt("HRegion")=rs("HRegion")
	 RSt("FRegion")=rs("FRegion")
	 RSt("Hcontent")=rs("Hcontent")
	 RSt("Fcontent")=rs("Fcontent")
	 RSt("ScopeOn")=rs("ScopeOn")
	 RSt("Hscope")=rs("Hscope")
	 RSt("Fscope")=rs("Fscope")
	 RSt("Hweburl")=rs("Hweburl")
	 RSt("Fweburl")=rs("Fweburl")
	 RSt("urlType")=rs("urlType")
	 RSt("Rurl")=rs("Rurl")
	 RSt("Reurl")=rs("Reurl")
	 RSt("Hpurl")=rs("Hpurl")
	 RSt("Fpurl")=rs("Fpurl")
	 RSt.Update
	 RSt.close 
	 set RSt=nothing
	Rs.MoveNext
	Loop
	Rs.Close
	Set Rs = Nothing
	 call Admin_ShowErr("导出采集规则成功<a href='collecttemp.mdb' ><font color='red' >点此下载采集规则库(collecttemp.mdb)</font></a>","admin_rules.asp",1)
else
call Admin_ShowErr("请选择需要导出的规则 ","admin_collect.asp",0)
end if
end sub

sub List()
Dim int_RPP : int_RPP=30
Dim sql,cPageNo,i
Dim rs
%>

<form name="forms" action="admin_collect.asp?action=Alldc" method="post">
<TABLE width="96%" border=0 align=center cellpadding="5" cellSpacing=1 class=tbtitle style="BACKGROUND: #cad9ea;">
 <TBODY>
 <tr bgColor="#f5fafe">
 <th  colspan="7" >采 集 项 目 管 理 </th>
   </tr>
 <tr bgColor="#f5fafe">
 <td width="10%"   align="left" >ID</td>
 <td width="15%">采集项目名称</td>
 <td width="22%">采集站点链接</td>
 <td width="10%">播放类型</td>
 <td width="10%">入库分类</td>
 <td width="13%">最后采集时间</td>
 <td width="20%">操 作</td>
 </tr>
 <% 
 set RS=Server.CreateObject("ADODB.Recordset")
 Sql="Select * from programe Order By ID Desc,ID"
 Rs.open sql,connc,1,2
 if Rs.eof Then
 Response.Write"<td  colspan=""7"" align=""center"" >暂无记录!</td>"
 else
 Rs.PageSize=int_RPP
 cPageNo=Request.QueryString("Page")
 If cPageNo="" Then cPageNo = 1
 If not isnumeric(cPageNo) Then cPageNo = 1
 cPageNo = Clng(cPageNo)
 If cPageNo>Rs.PageCount Then cPageNo=Rs.PageCount 
 If cPageNo<=0 Then cPageNo=1
 Rs.AbsolutePage=cPageNo 
 for i=1 to int_RPP
 if Rs.eof Then exit For  
%>
 <tr bgcolor="#FFFFFF">
 <td  ><input name="ID" type="checkbox" id="ID" value="<% = RS("ID")%>"> <%=RS("ID")%></td>
 <td><A href="admin_collect.asp?action=Edit&ID=<%=RS("ID")%>"><%=RS("CollectName")%></A></td>
 <td  >&nbsp;<A href="<%=RS("WebUrl")%>" target="_blank" ><%=left(RS("WebUrl"),25)%></A></td> 
 <td   ><%=RS("Server")%></td>
 <%if RS("ClassType")=1 Then
 response.write("<td  ><font color=red >自定义分类</font></td>")
 else
 %>
 <td  ><%=maxClassCN(RS("CollectClass"))%></td>
 <%end if%>
 <td   title="<%=RS("CollectTime")%>"><%if isDate(RS("CollectTime")) then isCurrentDay(formatdatetime(RS("CollectTime"),2))%></td>
 <td  ><A href="collect.asp?ID=<%= RS("ID") %>">采集</A>｜<A href="admin_collect.asp?action=Edit&ID=<%=RS("ID")%>">修改</A>｜<A href="admin_collect.asp?action=Copy&ID=<%= RS("ID") %>">复制</A>｜<A href="admin_collect.asp?action=Del&ID=<%=RS("ID")%>">删除</A></td>
 </tr>

 <%Rs.MoveNext
  next
  end if %>
  <tr bgcolor="#FFFFFF">
   <td height=27 colspan="7" align="center"  >全选<input type="checkbox" name="chkall" id="chkall" class="checkbox" onClick="checkAll(this.checked,'input','ID')" />反选<input type="checkbox" name="chkothers" id="chkothers" class="checkbox" onClick="checkOthers('input','ID')" />&nbsp;&nbsp;&nbsp;<input type="button" class="btn" name="Submit" value="批量删除"  onClick="document.forms.action='admin_collect.asp?action=Delall';{if(confirm('确定删除您所选择的影片吗？')){this.document.forms.submit();return true;}return false;}">&nbsp;<input type="button" class="btn"  style="background-color:#BFBFBF" name="Submit" value="导出选中规则" onClick="{if(confirm('确定导出选中规则吗？')){this.document.forms.submit();return true;}return false;}">
&nbsp; <% response.Write fPageCount(Rs,cPageNo) %></td>
   </tr>
   <tr bgcolor="#FFFFFF"><td colspan="7" >导入规则库 <br />
   <font  color="#999999">通过ftp直接上传规则库文件collecttemp.mdb至collect目录覆盖。 
</font>
   </td></tr>
</table>
</form>

<%
Rs.Close
set Rs = nothing
end sub
sub Del()
 connc.execute "delete from programe WHERE ID="&Request.QueryString("ID")
 call Admin_ShowErr("<li>采集项目删除成功！</li>","admin_collect.asp",1)
end sub

sub Delall()
 dim ids:ids=replace(request.Form("id")," ","")
 if not isNul(ids) then
	 connc.execute "delete from programe WHERE ID in ("&ids&")"
	 call Admin_ShowErr("<li>采集项目删除成功！</li>","admin_collect.asp",1)
 else
 	call Admin_ShowErr("<li>请选择相应项目！</li>","admin_collect.asp",0)
 end if
end sub

sub Add()%>

<form name="Form" action="admin_collect.asp?action=Add2" method="post">
<TABLE width="96%" border=0 align=center cellpadding="5" cellSpacing=1 class=tbtitle style="BACKGROUND: #cad9ea;">
 <tr bgColor="#f5fafe">
 <th  colspan="2" > 添 加 采 集 项 目 </th>
 </tr>
 <tr bgcolor="#FFFFFF">
 <td width="15%">采集名称：</td>
 <td width="85%"><input name="CollectName" type="text" id="CollectName" size="40"></td>
 </tr>
 <tr bgcolor="#FFFFFF">
 <td width="15%">目标网址：</td> 
 <td  ><input name="WebUrl" type="text" id="WebUrl" size="40"></td>
 </tr>
 <tr bgcolor="#FFFFFF">
 <td>网页编码：</td>
 <td><select name="selEncoding" size="1">
<option value="GB2312" selected="selected">GB2312</option>
<option value="UTF-8">UTF-8</option>
<option value="BIG5">BIG5</option>
</select></td>
</tr>

<tr bgcolor="#FFFFFF">
<td>播放类型：</td>
 <td>
  <select id='Server' name='Server'>
        <option value=''>暂没有数据</option>
       <%=GetShowPlaySelect("")%>
</select>

</td></tr>
<tr bgcolor="#FFFFFF">
<td>分页设置：</td>
 <td><input type="radio" value="0" name="ListPaingType" checked="checked" onClick="ChangeCutPara(0);">
不分页&nbsp;&nbsp;
<input type="radio" value="1" name="ListPaingType" onClick="ChangeCutPara(1);">
批量分页&nbsp;
<input type="radio" value="2" name="ListPaingType" onClick="ChangeCutPara(2);">
手动分页&nbsp;
<input type="radio" value="3" name="ListPaingType" onClick="ChangeCutPara(3);"> 
按ID直接采集内容</td>
 </tr>
 <tr bgcolor="#FFFFFF" ID="IndexCutPage">
 <td >采集地址：</td>
 <td><input name="ListPaingStr" type="text" size="60"></td>
 </tr>
 <tr bgcolor="#FFFFFF" ID="HandCutPage" style="display:none">
 <td><span id="CutPageName"></span>：</td>
 <td><input name="ListPaingStr2" type="text" value="" size="60">
 分页代码 <font color=red>{$ID}</font><br>
标准格式：Http://www.xxxxx.com/list/list_{$ID}.html<br>
采集范围：
<input name="ListPaingID1" type="text" value="0" size="4">
 To 
<input name="ListPaingID2" type="text" value="9" size="4">
例如：1 - 9</td>
 </tr>
 <tr bgcolor="#FFFFFF" ID="ListContent" style="display:none">
 <td>手动分页：</td>
 <td><textarea name="ListPaingStr3" cols="60" rows="3"></textarea></td>
 </tr>
 <tr bgcolor="#FFFFFF">
 <td>采集参数：</td>
 <td>
  <input name="CollecOrder" type="checkbox" value="1">
倒序采集&nbsp;&nbsp; <input name="SaveFiles" type="hidden" value="0">&nbsp; </td>
 </tr>
 <tr bgcolor="#FFFFFF">
 <td>过滤选项：</td>
 <td height=16 ><input name="Script_Iframe" type="checkbox" value="1" checked>
Iframe
<input name="Script_Object" type="checkbox" value="1" checked>
Object
<input name="Script_Script" type="checkbox" value="1" checked>
Script
<input name="Script_Div" type="checkbox" value="1" checked>
Div
<input name="Script_Class" type="checkbox" value="1" checked>
Class
<input name="Script_Table" type="checkbox" value="1" checked>
Table<br>
&nbsp;&nbsp; <br>
<input name="Script_Span" type="checkbox" value="1" checked>
Span
&nbsp; <input name="Script_Img" type="checkbox" value="1" checked>
Img&nbsp;&nbsp;&nbsp;
<input name="Script_Font" type="checkbox" value="1" checked>
Font&nbsp;&nbsp;
<input name="Script_A" type="checkbox" value="1" checked>
A    
&nbsp; <input name="Script_Html" type="checkbox" value="1" checked>
Html&nbsp;
<input name="Script_Td" type="checkbox" value="1" checked>
Td &nbsp;
<input name="Script_Tr" type="checkbox" value="1" checked>
Tr
&nbsp; <input type="hidden" value="0" name="RepeatCollect" /></td>
 </tr>

 <tr bgcolor="#FFFFFF">
 <td  colspan="2"  ><input type="submit" class="btn" name="Submit" value="下一步"></td>
 </tr>

</table>
</form></div>
<script language="JavaScript">
function ChangeCutPara(Flag)
{
 switch (Flag)
 {
 case 0 :
 document.all.IndexCutPage.style.display='';
 document.all.HandCutPage.style.display='none';
 document.all.ListContent.style.display='none';
 break;
 case 1 :
 document.all.IndexCutPage.style.display='none';
 document.all.HandCutPage.style.display='';
 document.all.ListContent.style.display='none';
 document.getElementById("CutPageName").innerHTML='批量分页';
 break;
 case 2 :
 document.all.IndexCutPage.style.display='none';
 document.all.HandCutPage.style.display='none';
 document.all.ListContent.style.display='';
 break;
 case 3 :
 document.all.IndexCutPage.style.display='none';
 document.all.HandCutPage.style.display='';
 document.all.ListContent.style.display='none';
 document.getElementById("CutPageName").innerHTML='按ID采集内容页';
 break;
 default :
 document.all.IndexCutPage.style.display='none';
 document.all.HandCutPage.style.display='none';
 document.all.ListContent.style.display='none';
 break;
 }
}
</script>
<%End Sub
Sub Add2()
dim ListUrl,ListCode,rs,sql,id

Select Case Request.Form("ListPaingType")
Case 0
  ListUrl=request.Form("ListPaingStr")
Case 1,3
  ListUrl=Replace(request.Form("ListPaingStr2"),"{$ID}",CStr(request.Form("ListPaingID1")))
Case 2
  If Instr(request.Form("ListPaingStr3"),"|")>0 Then
  ListUrl=Left(request.Form("ListPaingStr3"),Instr(request.Form("ListPaingStr3"),"|")-1)
  Else
  ListUrl=request.Form("ListPaingStr3")
  End If
End Select
 ListCode=GetHttpPage(ListUrl,Request.Form("selEncoding"))
 If ListCode=False Then
 call Admin_ShowErr("<li>在获取:"&ListUrl&"网页源码时发生错误！</li>","javascript:history.go(-1)",0)
 End If
 Session("ListUrl")=ListUrl
 Session("selEncoding")=Request.Form("selEncoding")
 Session("Server")=Request.Form("Server")
 'by shitou 2009-02-09
 'Session("Area")=Request.Form("Area")
 Session("ListCode")=ListCode
 set rs=Server.CreateObject("ADODB.Recordset")
 sql="select * from programe"
 Rs.open sql,connc,1,3
 RS.Addnew
 RS("CollectName")=Request.Form("CollectName")
 RS("selEncoding")=Request.Form("selEncoding")
 RS("WebUrl")=Request.Form("WebUrl")
 'RS("Area")=Request.Form("Area")
 RS("Server")=Request.Form("Server")
 RS("ListPaingType")=Request.Form("ListPaingType")
 RS("ListPaingStr")=Request.Form("ListPaingStr")
 RS("ListPaingStr2")=Request.Form("ListPaingStr2")
 RS("ListPaingID1")=Request.Form("ListPaingID1")
 RS("ListPaingID2")=Request.Form("ListPaingID2")
 RS("ListPaingStr3")=Request.Form("ListPaingStr3")
 RS("Script_Iframe")=Request.Form("Script_Iframe")
 RS("Script_Object")=Request.Form("Script_Object")
 RS("Script_Script")=Request.Form("Script_Script")
 RS("Script_Div")=Request.Form("Script_Div")
 RS("Script_Class")=Request.Form("Script_Class")
 RS("Script_Table")=Request.Form("Script_Table")
 RS("Script_Tr")=Request.Form("Script_Tr")
 RS("Script_Span")=Request.Form("Script_Span")
 RS("Script_Img")=Request.Form("Script_Img")
 RS("Script_Font")=Request.Form("Script_Font")
 RS("Script_A")=Request.Form("Script_A")
 RS("Script_Html")=Request.Form("Script_Html")
 RS("Script_Td")=Request.Form("Script_Td")
 RS("SaveFiles")=Request.Form("SaveFiles")
 RS("CollecOrder")=Request.Form("CollecOrder")
 'RS("cxcpDinShi")=Request.Form("cxcpDinShi")
 'RS("cxcpPicType")=Request.Form("cxcpPicType")
 RS("RepeatCollect")=Request.Form("RepeatCollect")
 'RS("cxcpReplaceType")=Request.Form("cxcpReplaceType")
 'RS("cxcpReplace")=Request.Form("cxcpReplace")
 'RS("Hits")=Request.Form("Hits")
 RS.Update
 ID=RS("ID")
 RS.close 
 set RS=nothing
 if Request.Form("ListPaingType")=3 then
 Response.Redirect "admin_collect.asp?action=Add3&ListPaingType="&Request.Form("ListPaingType")&"&ID="&ID
 end if%>
 <div class="container" id="cpcontainer">
<TABLE width="96%" border=0 align=center cellpadding="5" cellSpacing=1 class=tbtitle style="BACKGROUND: #cad9ea;">
 <form name="Form" action="admin_collect.asp?action=Add3" method="post">
 <tbody>
 <tr bgColor="#f5fafe">
 <th  colspan="2"  >采 集 列 表 连 接 设 置</th>
 </tr>
 <tr bgcolor="#FFFFFF">
 <td width="16%"   >影片列表开始代码：</td>
 <td width="84%"  >&nbsp;&nbsp;输入区域： <span onClick="if(document.Form.LsString.rows>2)document.Form.LsString.rows-=1" style='cursor:hand'><b>缩小</b></span> <span onClick="document.Form.LsString.rows+=1" style='cursor:hand'><b>扩大</b></span><br>
 <textarea name="LsString" cols="70" rows="3"></textarea></td>
 </tr>
 <tr bgcolor="#FFFFFF">
 <td>影片列表结束代码：</td>
 <td>&nbsp;&nbsp;输入区域： <span onClick="if(document.Form.LoString.rows>2)document.Form.LoString.rows-=1" style='cursor:hand'><b>缩小</b></span> <span onClick="document.Form.LoString.rows+=1" style='cursor:hand'><b>扩大</b></span><br>
 <textarea name="LoString" cols="70" rows="3"></textarea></td>
 </tr>
 <tr bgcolor="#FFFFFF">
 <td>影片链接开始代码：</td>
 <td>&nbsp;&nbsp;输入区域： <span onClick="if(document.Form.HsString.rows>2)document.Form.HsString.rows-=1" style='cursor:hand'><b>缩小</b></span> <span onClick="document.Form.HsString.rows+=1" style='cursor:hand'><b>扩大</b></span><br>
 <textarea name="HsString" cols="70" rows="3"></textarea></td>
 </tr>
 <tr bgcolor="#FFFFFF">
 <td>影片链接结束代码：</td>
 <td>&nbsp;&nbsp;输入区域： <span onClick="if(document.Form.HoString.rows>2)document.Form.HoString.rows-=1" style='cursor:hand'><b>缩小</b></span> <span onClick="document.Form.HoString.rows+=1" style='cursor:hand'><b>扩大</b></span><br>
 <textarea name="HoString" cols="70" rows="3"></textarea></td>
 </tr>
 <tr bgcolor="#FFFFFF">
 <td colspan="2"><input type="hidden" name="ID" id="ID" value="<%=ID%>">
  <input type="button" class="btn" name="button" value="上一步" onClick="window.location.href='javascript:history.go(-1)'">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
 <input name="Submit" type="submit" class="btn" id="Submit" value="下一步"></td>
 </tr>
 </tbody>
 </form>
</table>
</div>
<%end sub
sub Add3()
dim id,ListCode,NewsArrayCode,NewsArray,UrlTest,rs,sql,NewsCode

 if Request.QueryString("ListPaingType")<>"" then
 Session("NewsCode")=Session("ListCode")
 ID=Request.QueryString("ID")
 else
 ListCode=GetBody(Session("ListCode"),request.Form("LsString"),request.Form("LoString"))
 NewsArrayCode=GetArray(ListCode,request.Form("HsString"),request.Form("HoString"))
 Select Case NewsArrayCode
 Case False
 call Admin_ShowErr("<li>在获取链接列表时出错。</li>","javascript:history.go(-1)",0)
 Case Else
 NewsArray=Split(NewsArrayCode,"$Array$")
 UrlTest=NewsArray(0)
 UrlTest=DefiniteUrl(UrlTest,Session("ListUrl"))
 NewsCode=GetHttpPage(UrlTest,Session("selEncoding"))
 Session("NewsCode")=NewsCode
 Session("ListUrl")=UrlTest
 End Select
 set rs=Server.CreateObject("ADODB.Recordset")
 sql="select * from programe Where ID="&Request.Form("ID")&""
 Rs.open sql,connc,1,3
 RS("LsString")=Request.Form("LsString")
 RS("LoString")=Request.Form("LoString")
 RS("HsString")=Request.Form("HsString")
 RS("HoString")=Request.Form("HoString")
 RS.Update
 ID=RS("ID")
 if request("ClassType")="1" then
 CollectClass=0
 eles
 CollectClass=RS("CollectClass")
 end if
 RS.close 
 set RS=nothing
 end if%>
 <div class="container" id="cpcontainer">
<TABLE width="96%" border=0 align=center cellpadding="5" cellSpacing=1 class=tbtitle style="BACKGROUND: #cad9ea;">
 <form name="Form" action="admin_collect.asp?action=Add4" method="post">
 <tbody>
 <tr bgColor="#f5fafe">
 <th  colspan="2"  >采 集 内 容 与 影 片 地 址 设 置</th>
 </tr>
 <tr bgcolor="#FFFFFF">
 <td width="16%"   >影片名称开始代码：</td>
 <td width="84%"  >&nbsp;&nbsp;输入区域： <span onClick="if(document.Form.Htitle.rows>2)document.Form.Htitle.rows-=1" style='cursor:hand'><b>缩小</b></span> <span onClick="document.Form.Htitle.rows+=1" style='cursor:hand'><b>扩大</b></span><br>
 <textarea name="Htitle" cols="70" rows="3"></textarea></td>
 </tr>
 <tr bgcolor="#FFFFFF">
 <td>影片名称结束代码：</td>
 <td>&nbsp;&nbsp;输入区域： <span onClick="if(document.Form.Ftitle.rows>2)document.Form.Ftitle.rows-=1" style='cursor:hand'><b>缩小</b></span> <span onClick="document.Form.Ftitle.rows+=1" style='cursor:hand'><b>扩大</b></span><br>
 <textarea name="Ftitle" cols="70" rows="3"></textarea></td>
 </tr>
 <tr bgcolor="#FFFFFF">
 <td>影片演员开始代码：</td>
 <td>&nbsp;&nbsp;输入区域： <span onClick="if(document.Form.Hname.rows>2)document.Form.Hname.rows-=1" style='cursor:hand'><b>缩小</b></span> <span onClick="document.Form.Hname.rows+=1" style='cursor:hand'><b>扩大</b></span><br>
 <textarea name="Hname" cols="70" rows="3"></textarea></td>
 </tr>
 <tr bgcolor="#FFFFFF">
 <td>影片演员结束代码：</td>
 <td>&nbsp;&nbsp;输入区域： <span onClick="if(document.Form.Fname.rows>2)document.Form.Fname.rows-=1" style='cursor:hand'><b>缩小</b></span> <span onClick="document.Form.Fname.rows+=1" style='cursor:hand'><b>扩大</b></span><br>
 <textarea name="Fname" cols="70" rows="3"></textarea></td>
 </tr>
 <tr bgcolor="#FFFFFF">
        <td><font color="#FF0000">影片栏目设置：</font></td>
        <td><input type="radio" value="0" name="ClassType" onClick="HClassN.style.display='none';FClassN.style.display='none';CollectClassN.style.display='';CollectClassN2.style.display=''" checked>
          固定栏目&nbsp;&nbsp; <input type="radio" value="1" name="ClassType" onClick="ChangeCutPara(1,'CollectClassN','HClassN','FClassN');">
按对应栏目自动转换</td>
	  </tr>
	  <tr bgcolor="#FFFFFF" id="CollectClassN">
        <td><font color="#FF0000">选择入库栏目：</font></td>
        <td id="CollectClassN2"><select name="CollectClass" id="CollectClass" size="1">
	  	<option value="0">请选择入库分类</option>
		<% makeTypeOption 0,"&nbsp;|&nbsp;&nbsp;" %>
      </select></td>
      </tr>
      <tr bgcolor="#FFFFFF" id="HClassN">
        <td><font color="#FF0000">影片栏目开始代码：</font></td>
        <td>&nbsp;&nbsp;输入区域： <span onClick="if(document.Form.HClass.rows>2)document.Form.HClass.rows-=1" style='cursor:hand'><b>缩小</b></span> <span onClick="document.Form.HClass.rows+=1" style='cursor:hand'><b>扩大</b></span><br>
          <textarea name="HClass" cols="70" rows="7" id="HClass"></textarea></td>
      </tr>
      <tr bgcolor="#FFFFFF" id="FClassN">
        <td><font color="#FF0000">影片栏目结束代码：</font></td>
        <td>&nbsp;&nbsp;输入区域： <span onClick="if(document.Form.FClass.rows>2)document.Form.FClass.rows-=1" style='cursor:hand'><b>缩小</b></span> <span onClick="document.Form.FClass.rows+=1" style='cursor:hand'><b>扩大</b></span><br>
          <textarea name="FClass1" cols="70" rows="7" id="FClass"></textarea></td>
      </tr>	
  <tr bgcolor="#FFFFFF"> 
 <td >影片日期开始代码：</td>
 <td>&nbsp;&nbsp;输入区域： <span onClick="if(document.Form.Timea1.rows>2)document.Form.Timea1.rows-=1" style='cursor:hand'><b>缩小</b></span> <span onClick="document.Form.Timea1.rows+=1" style='cursor:hand'><b>扩大</b></span><br>
 <textarea name="Timea1" cols="70" rows="3"></textarea></td>
 </tr>
 <tr bgcolor="#FFFFFF">
 <td>影片日期结束代码：</td>
 <td>&nbsp;&nbsp;输入区域： <span onClick="if(document.Form.Timea2.rows>2)document.Form.Timea2.rows-=1" style='cursor:hand'><b>缩小</b></span> <span onClick="document.Form.Timea2.rows+=1" style='cursor:hand'><b>扩大</b></span><br>
 <textarea name="Timea2" cols="70" rows="3"></textarea></td>
 </tr>
 <tr bgcolor="#FFFFFF">
 <td>影片地区开始代码：</td>
 <td>&nbsp;&nbsp;输入区域： <span onClick="if(document.Form.Harea.rows>2)document.Form.Harea.rows-=1" style='cursor:hand'><b>缩小</b></span> <span onClick="document.Form.Harea.rows+=1" style='cursor:hand'><b>扩大</b></span><br>
 <textarea name="Harea" cols="70" rows="3"></textarea></td>
 </tr>
 
 <tr bgcolor="#FFFFFF">
 <td>影片地区结束代码：</td>
 <td>&nbsp;&nbsp;输入区域： <span onClick="if(document.Form.Farea.rows>2)document.Form.Farea.rows-=1" style='cursor:hand'><b>缩小</b></span> <span onClick="document.Form.Farea.rows+=1" style='cursor:hand'><b>扩大</b></span><br>
 <textarea name="Farea" cols="70" rows="3"></textarea></td>
 </tr>
 <tr bgcolor="#FFFFFF">
 <td>影片图片开始代码：</td>
 <td>&nbsp;&nbsp;输入区域： <span onClick="if(document.Form.Htupian.rows>2)document.Form.Htupian.rows-=1" style='cursor:hand'><b>缩小</b></span> <span onClick="document.Form.Htupian.rows+=1" style='cursor:hand'><b>扩大</b></span><br>
 <textarea name="Htupian" cols="70" rows="3" id="Htupian"></textarea></td>
 </tr>
 <tr bgcolor="#FFFFFF">
 <td>影片图片结束代码：</td>
 <td>&nbsp;&nbsp;输入区域： <span onClick="if(document.Form.Ftupian.rows>2)document.Form.Ftupian.rows-=1" style='cursor:hand'><b>缩小</b></span> <span onClick="document.Form.Ftupian.rows+=1" style='cursor:hand'><b>扩大</b></span><br>
 <textarea name="Ftupian" cols="70" rows="3" id="Ftupian"></textarea></td>
 </tr>
  <tr bgcolor="#FFFFFF">
 <td>影片图片替换代码：<br>图片地址前后加[变量]<br>不加变量请留空</td>
 <td>&nbsp;&nbsp;输入区域： <span onClick="if(document.Form.ListPaingStr3.rows>2)document.Form.ListPaingStr3.rows-=1" style='cursor:hand'><b>缩小</b></span> <span onClick="document.Form.ListPaingStr3.rows+=1" style='cursor:hand'><b>扩大</b></span><br>
 <textarea name="ListPaingStr3" cols="70" rows="3" id="ListPaingStr3"></textarea></td>
 </tr>
 <tr bgcolor="#FFFFFF">
 <td>影片介绍开始代码：</td>
 <td>&nbsp;&nbsp;输入区域： <span onClick="if(document.Form.Hcontent.rows>2)document.Form.Hcontent.rows-=1" style='cursor:hand'><b>缩小</b></span> <span onClick="document.Form.Hcontent.rows+=1" style='cursor:hand'><b>扩大</b></span><br>
 <textarea name="Hcontent" cols="70" rows="3" id="Hcontent"></textarea></td>
 </tr>
 <tr bgcolor="#FFFFFF">
 <td>影片介绍结束代码：</td>
 <td>&nbsp;&nbsp;输入区域： <span onClick="if(document.Form.Fcontent.rows>2)document.Form.Fcontent.rows-=1" style='cursor:hand'><b>缩小</b></span> <span onClick="document.Form.Fcontent.rows+=1" style='cursor:hand'><b>扩大</b></span><br>
 <textarea name="Fcontent" cols="70" rows="3" id="Fcontent"></textarea></td>
 </tr> 
 <tr bgcolor="#FFFFFF">
 <td>影片列表范围：</td>
 <td><input type="radio" value="0" name="ScopeOn" checked="checked" onClick="ScopeN1.style.display='none';ScopeN2.style.display='none'">
  关闭&nbsp;&nbsp; <input type="radio" value="1" name="ScopeOn" onClick="ScopeN1.style.display='';ScopeN2.style.display=''">
开启</td>
 </tr> 
 <tr bgcolor="#FFFFFF" id="ScopeN1" style="display:none;">
 <td>播放列表开始代码：</td>
 <td>&nbsp;&nbsp;输入区域： <span onClick="if(document.Form.Hscope.rows>2)document.Form.Hscope.rows-=1" style='cursor:hand'><b>缩小</b></span> <span onClick="document.Form.Hscope.rows+=1" style='cursor:hand'><b>扩大</b></span><br>
  <textarea name="Hscope" cols="70" rows="3" id="Hscope"></textarea></td>
 </tr>
 <tr bgcolor="#FFFFFF" id="ScopeN2" style="display:none;">
 <td>播放列表结束代码：</td>
 <td>&nbsp;&nbsp;输入区域： <span onClick="if(document.Form.Fscope.rows>2)document.Form.Fscope.rows-=1" style='cursor:hand'><b>缩小</b></span> <span onClick="document.Form.Fscope.rows+=1" style='cursor:hand'><b>扩大</b></span><br>
  <textarea name="Fscope" cols="70" rows="3" id="Fscope"></textarea></td>
 </tr>
 <tr bgcolor="#FFFFFF">
 <td>播放链接开始代码：</td>
 <td>&nbsp;&nbsp;输入区域： <span onClick="if(document.Form.Hweburl.rows>2)document.Form.Hweburl.rows-=1" style='cursor:hand'><b>缩小</b></span> <span onClick="document.Form.Hweburl.rows+=1" style='cursor:hand'><b>扩大</b></span><br>
  <textarea name="Hweburl" cols="70" rows="3" id="Hweburl"></textarea></td>
 </tr>
 <tr bgcolor="#FFFFFF">
 <td>播放链接结束代码：</td>
 <td>&nbsp;&nbsp;输入区域： <span onClick="if(document.Form.Fweburl.rows>2)document.Form.Fweburl.rows-=1" style='cursor:hand'><b>缩小</b></span> <span onClick="document.Form.Fweburl.rows+=1" style='cursor:hand'><b>扩大</b></span><br>
  <textarea name="Fweburl" cols="70" rows="3" id="Fweburl"></textarea></td>
 </tr>
 <tr bgcolor="#FFFFFF">
 <td>特殊播放链接处理：</td>
 <td><input type="radio" value="0" name="urlType" checked="checked" onClick="Listurl2.style.display='none';Listurl3.style.display='none'" >
不作设置&nbsp;&nbsp;
<input type="radio" value="1" name="urlType" onClick="Listurl2.style.display='';Listurl3.style.display=''" />
替换地址<br>
<font color="red">对于使用了JavaScript:openwindow形式的连接请使用以下格式处理:<br>
脚本连接:内容[变量] 内容 如:javaScript:OpenWnd([变量])<br>
实际连接:内容[变量] 内容 如:play.asp?id=[变量]</font></td>
 </tr>
 <tr bgcolor="#FFFFFF" id="Listurl2" style="display:none;">
 <td>要替换的地址：</td>
 <td>&nbsp;&nbsp;输入区域： <span onClick="if(document.Form.Rurl.rows>2)document.Form.Rurl.rows-=1" style='cursor:hand'><b>缩小</b></span> <span onClick="document.Form.Rurl.rows+=1" style='cursor:hand'><b>扩大</b></span> &nbsp;&nbsp;可用标签：<font onmouseover="getActiveText(document.Form.Rurl);" onClick="addTag('[变量]')" style="CURSOR: hand"><b>[变量]</b></font><br />
 <textarea name="Rurl" cols="70" rows="3" id="Rurl"></textarea></td>
 </tr>
 <tr bgcolor="#FFFFFF" id="Listurl3" style="display:none;">
 <td>替换为的地址：</td>
 <td>&nbsp;&nbsp;输入区域： <span onClick="if(document.Form.Reurl.rows>2)document.Form.Reurl.rows-=1" style='cursor:hand'><b>缩小</b></span> <span onClick="document.Form.Reurl.rows+=1" style='cursor:hand'><b>扩大</b></span> &nbsp;&nbsp;可用标签：<font onmouseover="getActiveText(document.Form.Reurl);" onClick="addTag('[变量]')" style="CURSOR: hand"><b>[变量]</b></font><br />
 <textarea name="Reurl" cols="70" rows="3" id="Reurl"></textarea></td>
 </tr>
 <tr bgcolor="#FFFFFF">
 <td>影片地址开始代码：</td>
 <td>&nbsp;&nbsp;输入区域： <span onClick="if(document.Form.Hpurl.rows>2)document.Form.Hpurl.rows-=1" style='cursor:hand'><b>缩小</b></span> <span onClick="document.Form.Hpurl.rows+=1" style='cursor:hand'><b>扩大</b></span><br>
  <textarea name="Hpurl" cols="70" rows="3" id="Hpurl"></textarea></td>
 </tr>
 <tr bgcolor="#FFFFFF">
 <td>影片地址结束代码：</td>
 <td>&nbsp;&nbsp;输入区域： <span onClick="if(document.Form.Fpurl.rows>2)document.Form.Fpurl.rows-=1" style='cursor:hand'><b>缩小</b></span> <span onClick="document.Form.Fpurl.rows+=1" style='cursor:hand'><b>扩大</b></span><br>
  <textarea name="Fpurl" cols="70" rows="3" id="Fpurl"></textarea></td>
 </tr>
 <tr bgcolor="#FFFFFF">
 <td colspan="2"><input name="button" type="button" class="btn" id="button" onClick="window.location.href='javascript:history.go(-1)'" value="上一步">
  &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
  <input type="hidden" name="ID" id="ID" value="<%=ID%>"><input name="Submit" type="submit" class="btn" id="Submit" value="下一步"></td>
 </tr>
 </tbody>
 </form>
</table></div>
<script language="JavaScript">
ChangeCutPara(0,'CollectClassN','HClassN','FClassN');
ChangeCutPara(0,'CollectRegionN','HRegionN','FRegionN');
function ChangeCutPara(Flag,name1,name2,name3)
{
 switch (Flag)
 {
 case 0 :
 document.getElementById(name1).style.display="block";
 document.getElementById(name2).style.display="none";
 document.getElementById(name3).style.display="none";
 break;
 case 1 :
 document.getElementById(name1).style.display="none";
 document.getElementById(name2).style.display="block";
 document.getElementById(name3).style.display="block";
 break;
 default :
 document.getElementById(name1).style.display="none";
 document.getElementById(name2).style.display="none";
 document.getElementById(name3).style.display="none";
 break;
 }
}
</script>
<%end sub
sub Add4()

dim rs,sql,ID,title,area,Name,tupian,content,weburl,webArray,i,UrlTest,webCode,url
dim Timea,typeId,typeidname,Urlscope

 set rs=Server.CreateObject("ADODB.Recordset")
 sql="select * from programe Where ID="&Request.Form("ID")&""
 Rs.open sql,connc,1,3
 RS("Htitle")=Request.Form("Htitle")
 RS("ListPaingStr3")=Request.Form("ListPaingStr3") 
 RS("Ftitle")=Request.Form("Ftitle")
 RS("Harea")=Request.Form("Harea")
 RS("Farea")=Request.Form("Farea")
 RS("Hname")=Request.Form("Hname")
 RS("Fname")=Request.Form("Fname")
 RS("Timea1")=Request.Form("Timea1")
 RS("Timea2")=Request.Form("Timea2")
 RS("Htupian")=Request.Form("Htupian")
 RS("Ftupian")=Request.Form("Ftupian")
 RS("ClassType")=Request.Form("ClassType")
 RS("CollectClass")=Request.Form("CollectClass")
 RS("HClass")=Request.Form("HClass")
 RS("FClass")=Request.Form("FClass")
 RS("RegionType")=Request.Form("RegionType")
 RS("CollectRegion")=Request.Form("CollectRegion")
 RS("HRegion")=Request.Form("HRegion")
 RS("FRegion")=Request.Form("FRegion")
 RS("Hcontent")=Request.Form("Hcontent")
 RS("Fcontent")=Request.Form("Fcontent")
 RS("ScopeOn")=Request.Form("ScopeOn")
 RS("Hscope")=Request.Form("Hscope")
 RS("Fscope")=Request.Form("Fscope")
 RS("Hweburl")=Request.Form("Hweburl")
 RS("Fweburl")=Request.Form("Fweburl")
 RS("urlType")=Request.Form("urlType")
 RS("Rurl")=Request.Form("Rurl")
 RS("Reurl")=Request.Form("Reurl")
 RS("Hpurl")=Request.Form("Hpurl")
 RS("Fpurl")=Request.Form("Fpurl")
 RS.Update
 ID=RS("ID")
 RS.close 
 set RS=nothing

title=GetBody(Session("NewsCode"),request.Form("Htitle"),request.Form("Ftitle"))
area=GetBody(Session("NewsCode"),request.Form("Harea"),request.Form("Farea"))
name=GetBody(Session("NewsCode"),request.Form("Hname"),request.Form("Fname"))
Timea=GetBody(Session("NewsCode"),request.Form("Timea1"),request.Form("Timea2"))
if request.Form("ClassType")=1 then
	typeid=GetBody(Session("NewsCode"),request.Form("HClass"),request.Form("FClass"))
	typeidname=typeid
else
	typeid=Request.Form("CollectClass")
	typeidname= GetDicText("tbl_type","t_name","t_id",typeid)
end if
tupian=GetBody(Session("NewsCode"),request.Form("Htupian"),request.Form("Ftupian"))
if Request.Form("ListPaingStr3")<>"" then
tupian=Replace(Request.Form("ListPaingStr3"),"[变量]",tupian)
end if
 
content=GetBody(Session("NewsCode"),request.Form("Hcontent"),request.Form("Fcontent"))
if Request.Form("ScopeOn")=1 then
Urlscope=GetBody(Session("NewsCode"),request.Form("Hscope"),request.Form("Fscope"))
weburl=GetArray(Urlscope,request.Form("Hweburl"),request.Form("Fweburl"))
else
weburl=GetArray(Session("NewsCode"),request.Form("Hweburl"),request.Form("Fweburl"))
end if%>
<div class="container" id="cpcontainer">
<TABLE width="96%" border=0 align=center cellpadding="5" cellSpacing=1 class=tbtitle style="BACKGROUND: #cad9ea;">
 <form name="form" action="admin_collect.asp?action=AddSever" method="post">
 <tbody>
 <tr bgColor="#f5fafe">
 <th colspan="2"  >采 集 测 试 结 果 </th>
 </tr>
 <tr bgcolor="#FFFFFF">
 <td width="16%" height=31  >影片名称：</td>
 <td width="84%" height=31 ><%=title%></td>
 </tr>
 <tr bgcolor="#FFFFFF">
 <td>影片演员：</td>
 <td><%=name%></td>
 </tr>
  <tr bgcolor="#FFFFFF">
 <td>影片日期：</td>
 <td><%=Timea%></td>
 </tr>
 <tr bgcolor="#FFFFFF">
   <td>影片栏目：</td>
 <td ><%=typeidname%></td>
 </tr>
 <tr bgcolor="#FFFFFF">
 <td>影片地区：</td>
 <td><%=transferArea(area)%></td>
 </tr>
 <tr bgcolor="#FFFFFF">
 <td>影片图片：</td>
 <td><%=tupian%></td>
 </tr>
 
 <tr bgcolor="#FFFFFF">
 <td>影片介绍：</td>
 <td><%=content%></td>
 </tr>
 <%If weburl<>False Then
 webArray=Split(weburl,"$Array$")
 For i=0 To Ubound(webArray)
 UrlTest=webArray(i)
 if Request.Form("UrlType")=1 then
 Keyurl = Split(Request.Form("Rurl"),"[变量]",-1,1)
 urli=GetBody(UrlTest,Keyurl(0),Keyurl(1))
 if urli=False then
 Exit For
 end if
 UrlTest=Replace(Request.Form("Reurl"),"[变量]",urli)
 end if
 UrlTest=DefiniteUrl(UrlTest,Session("ListUrl"))
 webCode=GetHttpPage(UrlTest,Session("selEncoding"))
 url=GetBody(webCode,Request.Form("Hpurl"),request.Form("Fpurl"))%>
 <tr bgcolor="#FFFFFF">
 <td>播放列表：</td>
 <td><%=UrlTest%></td>
 </tr>
 <tr bgcolor="#FFFFFF">
 <td>影片地址：</td>
 <td><%=url%></td>
 </tr>
 <%Next
 End if%>
 <tr bgcolor="#FFFFFF">
 <td  colspan="2"><input name="button" type="button" class="btn" id="button" onClick="window.location.href='javascript:history.go(-1)'" value="上一步">
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
<input name="Submit" type="submit" class="btn" id="Submit" value="完 成"></td>
 </tr>
 </tbody>
 </form>
</table></div>
<%end sub


sub Edit()
dim rs,sql
dim ID,CollectName,selEncoding,Server1,ClassID,WebUrl
dim ListPaingStr,ListPaingType,ListPaingStr2,ListPaingID1,ListPaingID2,ListPaingStr3
dim 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
dim SaveFiles,CollecOrder,RepeatCollect

 set rs=Server.CreateObject("ADODB.Recordset")
sql="select * from programe where id="&Request.QueryString("id")
RS.open sql,connc,1,1
ID=RS("ID")
CollectName=RS("CollectName")
selEncoding=RS("selEncoding")
Server1=RS("Server")
'Area=RS("Area")
WebUrl=RS("WebUrl") 
ListPaingStr=RS("ListPaingStr")
ListPaingType=RS("ListPaingType")
ListPaingStr2=RS("ListPaingStr2")
ListPaingID1=RS("ListPaingID1")
ListPaingID2=RS("ListPaingID2")
ListPaingStr3=RS("ListPaingStr3")
Script_Iframe=RS("Script_Iframe")
Script_Object=RS("Script_Object")
Script_Script=RS("Script_Script")
Script_Div=RS("Script_Div")
Script_Class=RS("Script_Class")
Script_Table=RS("Script_Table")
Script_Tr=RS("Script_Tr")
Script_Span=RS("Script_Span")
Script_Img=RS("Script_Img")
Script_Font=RS("Script_Font")
Script_A=RS("Script_A")
Script_Html=RS("Script_Html")
Script_Td=RS("Script_Td")
SaveFiles=RS("SaveFiles")
CollecOrder=RS("CollecOrder")
'cxcpDinShi=RS("cxcpDinShi")
'cxcpPicType=RS("cxcpPicType")
RepeatCollect=RS("RepeatCollect")
'cxcpReplaceType=RS("cxcpReplaceType")
'cxcpReplace=RS("cxcpReplace")
'Hits=RS("Hits")
RS.Close
Set RS=Nothing
%> 
<div class="container" id="cpcontainer">
<TABLE width="96%" border=0 align=center cellpadding="5" cellSpacing=1 class=tbtitle style="BACKGROUND: #cad9ea;">
 <form name="Form" action="admin_collect.asp?action=Edit2" method="post">
 <tbody>
 <tr bgColor="#f5fafe">
 <th colspan="2">采集项目修改</th>
 </tr>
 <tr bgcolor="#FFFFFF">
 <td width="16%">采集名称：</td>
 <td width="84%"><input name="CollectName" type="text" id="CollectName" value="<%=CollectName%>" size="40"></td>
 </tr>
 <tr bgcolor="#FFFFFF">
 <td width="16%"   >目标网址：</td> 
 <td ><input name="WebUrl" type="text" id="WebUrl" value="<%=WebUrl%>" size="40"></td> 
 </tr>
 <tr bgcolor="#FFFFFF">
 <td>网页编码：</td>
 <td><select name="selEncoding" size="1">
  <option value="GB2312" <%if selEncoding="GB2312" then Response.Write"selected"%>>GB2312</option>
  <option value="UTF-8" <%if selEncoding="UTF-8" then Response.Write"selected"%>>UTF-8</option>
  <option value="BIG5" <%if selEncoding="BIG5" then Response.Write"selected"%>>BIG5</option>
 </select></td>
 </tr>
 
 <tr bgcolor="#FFFFFF">
<td>播放类型：</td>
 <td>
<select name="Server">
 <option value=''>暂没有数据</option>
      <%=Server1&"---qiushi"%> <%=GetShowPlaySelect(Server1)%>
        </select>
 &nbsp; 
</td>
 
 </tr>
 <tr bgcolor="#FFFFFF">
 <td>分页设置：</td>
 <td><input type="radio" value="0" name="ListPaingType" checked="checked" onClick="ChangeCutPara(0);" <% if ListPaingType=0 then Response.Write "checked" %>>
不分页&nbsp;&nbsp;
<input type="radio" value="1" name="ListPaingType" onClick="ChangeCutPara(1);" <% if ListPaingType=1 then Response.Write "checked" %>>
批量分页&nbsp;
<input type="radio" value="2" name="ListPaingType" onClick="ChangeCutPara(2);" <% if ListPaingType=2 then Response.Write "checked" %>>
手动分页&nbsp;
<input type="radio" value="3" name="ListPaingType" onClick="ChangeCutPara(3);" <% if ListPaingType=3 then Response.Write "checked" %>>
按ID直接采集内容页</td>
 </tr>
 <tr ID="IndexCutPage" bgcolor="#FFFFFF">
 <td>采集网址：</td>
 <td><input name="ListPaingStr" type="text" size="60" value="<%=ListPaingStr%>"></td>
 </tr>
 <tr ID="HandCutPage" bgcolor="#FFFFFF">
 <td><span id="CutPageName"></span>：</td>
 <td><input name="ListPaingStr2" type="text" value="<%=ListPaingStr2%>" size="60">
  分页代码 <font color=red>{$ID}</font><br>
  标准格式：Http://www.xxxxx.com/list/list_{$ID}.html<br>
  生成范围：
  <input name="ListPaingID1" type="text" size="4" value="<%=ListPaingID1%>">
  To 
  <input name="ListPaingID2" type="text" size="4" value="<%=ListPaingID2%>">
  例如：1 - 9</td>
 </tr>
 <tr ID="ListContent" bgcolor="#FFFFFF">
 <td>手动分页：</td>
 <td><textarea name="ListPaingStr3" cols="60" rows="3"><%=ListPaingStr3%></textarea></td>
 </tr>
 <tr bgcolor="#FFFFFF">
 <td>采集参数：</td>
 <td> 

          <input name="CollecOrder" type="checkbox" value="1" <%If CollecOrder=1 Then response.write "checked"%>>
		  倒序采集     &nbsp;&nbsp;
		    <input name="SaveFiles" type="hidden" value="0">	      &nbsp;&nbsp;</td>
 </tr>
 <tr bgcolor="#FFFFFF">
 <td>过滤选项：</td>
 <td height=16 ><input name="Script_Iframe2" type="checkbox" value="1">
  Iframe
  <input name="Script_Object" type="checkbox" value="1" <%If Script_Object=1 Then response.write "checked"%>>
  Object
  <input name="Script_Script" type="checkbox" value="1" <%If Script_Script=1 Then response.write "checked"%>>
  Script
  <input name="Script_Div" type="checkbox" value="1" <%If Script_Div=1 Then response.write "checked"%>>
  Div
  <input name="Script_Class" type="checkbox" value="1" <%If Script_Class=1 Then response.write "checked"%>>
  Class
  <input name="Script_Table" type="checkbox" value="1" <%If Script_Table=1 Then response.write "checked"%>>
  Table<br>
<br>
<input name="Script_Span" type="checkbox" value="1" <%If Script_Span=1 Then response.write "checked"%>>
  Span     
  &nbsp; <input name="Script_Img" type="checkbox" value="1" <%If Script_Img=1 Then response.write "checked"%>>
  Img
  &nbsp;&nbsp; <input name="Script_Font" type="checkbox" value="1" <%If Script_Font=1 Then response.write "checked"%>>
  Font
  &nbsp; <input name="Script_A" type="checkbox" value="1" <%If Script_A=1 Then response.write "checked"%>>
  A
 &nbsp; <input name="Script_Html" type="checkbox" value="1" <%If Script_Html=1 Then response.write "checked"%>>
  Html&nbsp;
 <input name="Script_Td" type="checkbox" value="1" <%If Script_Td=1 Then response.write "checked"%>>
  Td&nbsp;
 <input name="Script_Tr" type="checkbox" value="1" <%If Script_Tr=1 Then response.write "checked"%>>
Tr 
 <input type="hidden" value="<%=RepeatCollect%>" name="RepeatCollect" />
</td>
 </tr>
 
 
  <tr bgcolor="#FFFFFF">
 <td colspan="2"  > <input type="hidden" name="ID" id="ID" value="<%=ID%>"><input type="submit" class="btn" name="Submit" value="下一步"></td>
 </tr>
 </tbody>
 </form>
</table></div>
<script language="JavaScript">
ChangeCutPara(<%=ListPaingType%>);
function ChangeCutPara(Flag)
{
 switch (Flag)
 {
 case 0 :
 document.all.IndexCutPage.style.display='';
 document.all.HandCutPage.style.display='none';
 document.all.ListContent.style.display='none';
 break;
 case 1 :
 document.all.IndexCutPage.style.display='none';
 document.all.HandCutPage.style.display='';
 document.all.ListContent.style.display='none';
 document.getElementById("CutPageName").innerHTML='批量分页';
 break;
 case 2 :
 document.all.IndexCutPage.style.display='none';
 document.all.HandCutPage.style.display='none';
 document.all.ListContent.style.display='';
 break;
 case 3 :
 document.all.IndexCutPage.style.display='none';
 document.all.HandCutPage.style.display='';
 document.all.ListContent.style.display='none';
 document.getElementById("CutPageName").innerHTML='按ID采集内容页';
 break;
 default :
 document.all.IndexCutPage.style.display='none';
 document.all.HandCutPage.style.display='none';
 document.all.ListContent.style.display='none';
 break;
 }
}
</script>
<%end sub
sub Edit2()

dim ListUrl,ListCode,ClassID,rs,sql,id,LsString,LoString,HsString,HoString,Htupian,Ftupian

Select Case Request.Form("ListPaingType")
Case 0
  ListUrl=request("ListPaingStr")
Case 1,3
  ListUrl=Replace(request.Form("ListPaingStr2"),"{$ID}",CStr(request.Form("ListPaingID1")))
Case 2
  If Instr(request.Form("ListPaingStr3"),"|")>0 Then
  ListUrl=Left(request.Form("ListPaingStr3"),Instr(request.Form("ListPaingStr3"),"|")-1)
  Else
  ListUrl=request.Form("ListPaingStr3")
  End If
End Select
 ListCode=GetHttpPage(ListUrl,Request.Form("selEncoding"))
 If ListCode=False Then
 call Admin_ShowErr("<li>在获取:"&ListUrl&"网页源码时发生错误！</li>","javascript:history.go(-1)",0)
 End If
 Session("ListUrl")=ListUrl
 Session("selEncoding")=Request.Form("selEncoding")
 Session("ListCode")=ListCode
Set Rs=Server.CreateObject("ADODB.Recordset")
 sql="select * from programe Where ID="&Request.Form("ID")
 Rs.open sql,connc,1,3

RS("CollectName")=Request.Form("CollectName")
RS("Server")=Request.Form("Server")
'RS("Area")=Request.Form("Area")
RS("WebUrl")=Request.Form("WebUrl")
 RS("selEncoding")=Request.Form("selEncoding")
 RS("ListPaingType")=Request.Form("ListPaingType")
 RS("ListPaingStr")=Request.Form("ListPaingStr")
 RS("ListPaingStr2")=Request.Form("ListPaingStr2")
 RS("ListPaingID1")=request.form("ListPaingID1")
 RS("ListPaingID2")=Request.Form("ListPaingID2")
 RS("ListPaingStr3")=Request.Form("ListPaingStr3")
 RS("Script_Iframe")=Request.Form("Script_Iframe")
 RS("Script_Object")=Request.Form("Script_Object")
 RS("Script_Script")=Request.Form("Script_Script")
 RS("Script_Div")=Request.Form("Script_Div")
 RS("Script_Class")=Request.Form("Script_Class")
 RS("Script_Table")=Request.Form("Script_Table")
 RS("Script_Tr")=Request.Form("Script_Tr")
 RS("Script_Span")=Request.Form("Script_Span")
 RS("Script_Img")=Request.Form("Script_Img")
 RS("Script_Font")=Request.Form("Script_Font")
 RS("Script_A")=Request.Form("Script_A")
 RS("Script_Html")=Request.Form("Script_Html")
 RS("Script_Td")=Request.Form("Script_Td")
 RS("SaveFiles")=Request.Form("SaveFiles")
 RS("CollecOrder")=Request.Form("CollecOrder")
 RS("RepeatCollect")=Request.Form("RepeatCollect")
 RS.Update
 ID=RS("ID")
 LsString=RS("LsString")
 LoString=RS("LoString")
 HsString=RS("HsString")
 HoString=RS("HoString")
 Htupian=RS("Htupian")
 Ftupian=RS("Ftupian")
 RS.close 
 set RS=nothing
 if Request.Form("ListPaingType")=3 then
 Response.Redirect"admin_collect.asp?action=Edit3&ListPaingType="&Request.Form("ListPaingType")&"&ID="&ID
 Response.end()
 end if%>
 <div class="container" id="cpcontainer">
<TABLE width="96%" border=0 align=center cellpadding="5" cellSpacing=1 class=tbtitle style="BACKGROUND: #cad9ea;">
 <form name="Form" action="admin_collect.asp?action=Edit3" method="post">
 <tbody>
 <tr bgColor="#f5fafe">
 <th colspan="2">采 集 列 表 连 接 设 置</th>
 </tr>
 <tr bgcolor="#FFFFFF">
 <td width="16%">影片列表开始代码：</td>
 <td width="84%">&nbsp;&nbsp;输入区域： <span onClick="if(document.Form.LsString.rows>2)document.Form.LsString.rows-=1" style='cursor:hand'><b>缩小</b></span> <span onClick="document.Form.LsString.rows+=1" style='cursor:hand'><b>扩大</b></span><br>
  <textarea name="LsString" cols="70" rows="3"><%=LsString%></textarea></td>
 </tr>
 <tr bgcolor="#FFFFFF">
 <td>影片列表结束代码：</td>
 <td>&nbsp;&nbsp;输入区域： <span onClick="if(document.Form.LoString.rows>2)document.Form.LoString.rows-=1" style='cursor:hand'><b>缩小</b></span> <span onClick="document.Form.LoString.rows+=1" style='cursor:hand'><b>扩大</b></span><br>
  <textarea name="LoString" cols="70" rows="3"><%=LoString%></textarea></td>
 </tr>
 <tr bgcolor="#FFFFFF">
 <td>影片链接开始代码：</td>
 <td>&nbsp;&nbsp;输入区域： <span onClick="if(document.Form.HsString.rows>2)document.Form.HsString.rows-=1" style='cursor:hand'><b>缩小</b></span> <span onClick="document.Form.HsString.rows+=1" style='cursor:hand'><b>扩大</b></span><br>
  <textarea name="HsString" cols="70" rows="3"><%=HsString%></textarea></td>
 </tr>
 <tr bgcolor="#FFFFFF">
 <td>影片链接结束代码：</td>
 <td>&nbsp;&nbsp;输入区域： <span onClick="if(document.Form.HoString.rows>2)document.Form.HoString.rows-=1" style='cursor:hand'><b>缩小</b></span> <span onClick="document.Form.HoString.rows+=1" style='cursor:hand'><b>扩大</b></span><br>
  <textarea name="HoString" cols="70" rows="3"><%=HoString%></textarea></td>
 </tr>
 <tr bgcolor="#FFFFFF">
 <td colspan="2"  ><input type="hidden" name="ID" id="ID" value="<%=ID%>">
  <input type="button" class="btn" name="button" value="上一步" onClick="window.location.href='javascript:history.go(-1)'">
  &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
  <input name="Submit" type="submit" class="btn" id="Submit" value="下一步"></td>
 </tr>
 </tbody>
 </form>
</table></div>
<%end sub
sub Edit3()
dim ListCode,NewsArrayCode,NewsArray,UrlTest,NewsCode,rs,sql,id,Htitle,Ftitle,Hname,Fname,Harea,Farea,Htupian,Ftupian,RegionType,CollectRegion,HRegion,FRegion,ClassType,CollectClass,HClass,FClass,Hcontent,Fcontent,ListPaingStr3,ScopeOn,Hscope,Fscope,Hweburl,Fweburl,urlType,Rurl,Reurl,Hpurl,Fpurl
dim Timea1,Timea2

 if Request.QueryString("ListPaingType")<>"" then
 Session("NewsCode")=Session("ListCode")
 else
 ListCode=GetBody(Session("ListCode"),request.Form("LsString"),request.Form("LoString"))
 NewsArrayCode=GetArray(ListCode,request.Form("HsString"),request.Form("HoString"))
 Select Case NewsArrayCode
 Case False
 call Admin_ShowErr("<li>在获取链接列表时出错。</li>","javascript:history.go(-1)",0)
 Case Else
 NewsArray=Split(NewsArrayCode,"$Array$")
 UrlTest=NewsArray(0)
 UrlTest=DefiniteUrl(UrlTest,Session("ListUrl"))
 NewsCode=GetHttpPage(UrlTest,Session("selEncoding"))
 Session("NewsCode")=NewsCode
 Session("ListUrl")=UrlTest
 End Select
 end if
 set rs=Server.CreateObject("ADODB.Recordset")
 sql="select * from programe Where ID="&Request("ID")&""
 Rs.open sql,connc,1,3
 RS("LsString")=Request.Form("LsString")
 RS("LoString")=Request.Form("LoString")
 RS("HsString")=Request.Form("HsString")
 RS("HoString")=Request.Form("HoString")
 RS.Update
 ID=RS("ID")
 Htitle=RS("Htitle")
 Ftitle=RS("Ftitle")
 Hname=RS("Hname")
 Fname=RS("Fname")
 Timea1=RS("Timea1")
 Timea2=RS("Timea2")
 Harea=RS("Harea")
 Farea=RS("Farea")
 Htupian=RS("Htupian")
 Ftupian=RS("Ftupian")
 RegionType=RS("RegionType")
 CollectRegion=RS("CollectRegion")
 HRegion=RS("HRegion")
 FRegion=RS("FRegion")
 CollectClass=RS("CollectClass")
 ClassType=RS("ClassType")
 HClass=RS("HClass")
 FClass=RS("FClass")
 Hcontent=RS("Hcontent")
 Fcontent=RS("Fcontent")
 ListPaingStr3=RS("ListPaingStr3")
 ScopeOn=RS("ScopeOn")
 Hscope=RS("Hscope")
 Fscope=RS("Fscope")
 Hweburl=RS("Hweburl")
 Fweburl=RS("Fweburl")
 urlType=RS("urlType")
 Rurl=RS("Rurl")
 Reurl=RS("Reurl")
 Hpurl=RS("Hpurl")
 Fpurl=RS("Fpurl")
 RS.close 
 set RS=nothing%>
 <div class="container" id="cpcontainer">
<TABLE width="96%" border=0 align=center cellpadding="5" cellSpacing=1 class=tbtitle style="BACKGROUND: #cad9ea;">
 <form name="Form" action="admin_collect.asp?action=Add4" method="post">
 <tbody>
 <tr bgColor="#f5fafe">
 <th  colspan="2"  >采 集 内 容 与 影 片 地 址 设 置</th>
 </tr>
 <tr bgcolor="#FFFFFF">
 <td width="16%">影片名称开始代码：</td>
 <td width="84%">&nbsp;&nbsp;输入区域： <span onClick="if(document.Form.Htitle.rows>2)document.Form.Htitle.rows-=1" style='cursor:hand'><b>缩小</b></span> <span onClick="document.Form.Htitle.rows+=1" style='cursor:hand'><b>扩大</b></span><br>
  <textarea name="Htitle" cols="70" rows="3" id="Htitle"><%=Htitle%></textarea></td>
 </tr>
 <tr bgcolor="#FFFFFF">
 <td>影片名称结束代码：</td>
 <td>&nbsp;&nbsp;输入区域： <span onClick="if(document.Form.Ftitle.rows>2)document.Form.Ftitle.rows-=1" style='cursor:hand'><b>缩小</b></span> <span onClick="document.Form.Ftitle.rows+=1" style='cursor:hand'><b>扩大</b></span><br>
  <textarea name="Ftitle" cols="70" rows="3" id="Ftitle"><%=Ftitle%></textarea></td>
 </tr>
 <tr bgcolor="#FFFFFF">
 <td>影片演员开始代码：</td>
 <td>&nbsp;&nbsp;输入区域： <span onClick="if(document.Form.Hname.rows>2)document.Form.Hname.rows-=1" style='cursor:hand'><b>缩小</b></span> <span onClick="document.Form.Hname.rows+=1" style='cursor:hand'><b>扩大</b></span><br>
  <textarea name="Hname" cols="70" rows="3" id="Hname"><%=Hname%></textarea></td>
 </tr>
 <tr bgcolor="#FFFFFF">
 <td>影片演员结束代码：</td>
 <td>&nbsp;&nbsp;输入区域： <span onClick="if(document.Form.Fname.rows>2)document.Form.Fname.rows-=1" style='cursor:hand'><b>缩小</b></span> <span onClick="document.Form.Fname.rows+=1" style='cursor:hand'><b>扩大</b></span><br>
  <textarea name="Fname" cols="70" rows="3" id="Fname"><%=Fname%></textarea></td>
 </tr>
 <tr bgcolor="#FFFFFF">
        <td><font color="#FF0000">影片栏目设置：</font></td>
        <td>
		<input type="radio" value="0" name="ClassType" onClick="HClassN.style.display='none';FClassN.style.display='none';CollectClassN.style.display='';CollectClassN2.style.display=''" <% if ClassType=0 then Response.Write "checked" %>>
          固定栏目&nbsp;&nbsp; 
		<input type="radio" value="1" name="ClassType" onClick="CollectClassN.style.display='none';CollectClassN2.style.display='none';HClassN.style.display='';FClassN.style.display=''" <% if ClassType=1 then Response.Write "checked" %>>
按对应栏目自动转换</td>
	  </tr>
	  <tr bgcolor="#FFFFFF" id="CollectClassN" <% if ClassType=1 then Response.Write "style=""display:none""" %>>
        <td><font color="#FF0000">选择入库栏目：</font></td>
        <td id="CollectClassN2">
		<select name="CollectClass" id="CollectClass" size="1">
	  	<option value="0">请选择入库分类</option>
		<% makeTypeOptionSelected 0,"&nbsp;|&nbsp;&nbsp;",CollectClass %>
      </select></td>
      </tr>
      <tr bgcolor="#FFFFFF" id="HClassN" <% if ClassType=0 then Response.Write "style=""display:none""" %>>
        <td><font color="#FF0000">影片栏目开始代码：</font></td>
        <td>&nbsp;&nbsp;输入区域： <span onClick="if(document.Form.HClass.rows>2)document.Form.HClass.rows-=1" style='cursor:hand'><b>缩小</b></span> <span onClick="document.Form.HClass.rows+=1" style='cursor:hand'><b>扩大</b></span><br>
          <textarea name="HClass" cols="70" rows="3" id="HClass"><%=HClass%></textarea></td>
      </tr>
      <tr bgcolor="#FFFFFF" id="FClassN" <% if ClassType=0 then Response.Write "style=""display:none""" %>>
        <td><font color="#FF0000">影片栏目结束代码：</font></td>
        <td>&nbsp;&nbsp;输入区域： <span onClick="if(document.Form.FClass.rows>2)document.Form.FClass.rows-=1" style='cursor:hand'><b>缩小</b></span> <span onClick="document.Form.FClass.rows+=1" style='cursor:hand'><b>扩大</b></span><br>
          <textarea name="FClass" cols="70" rows="3" id="FClass"><%=FClass%></textarea></td>
      </tr>	
  <tr bgcolor="#FFFFFF">
 <td>影片日期开始代码：</td>
 <td>&nbsp;&nbsp;输入区域： <span onClick="if(document.Form.Timea1.rows>2)document.Form.Timea1.rows-=1" style='cursor:hand'><b>缩小</b></span> <span onClick="document.Form.Timea1.rows+=1" style='cursor:hand'><b>扩大</b></span><br>
  <textarea name="Timea1" cols="70" rows="3" id="Timea1"><%=Timea1%></textarea></td>
 </tr>
 <tr bgcolor="#FFFFFF">
 <td>影片日期结束代码：</td>
 <td>&nbsp;&nbsp;输入区域： <span onClick="if(document.Form.Timea2.rows>2)document.Form.Timea2.rows-=1" style='cursor:hand'><b>缩小</b></span> <span onClick="document.Form.Timea2.rows+=1" style='cursor:hand'><b>扩大</b></span><br>
  <textarea name="Timea2" cols="70" rows="3" id="Timea2"><%=Timea2%></textarea></td>
 </tr>
 
  <tr bgcolor="#FFFFFF">
 <td>影片地区开始代码：</td>
 <td>&nbsp;&nbsp;输入区域： <span onClick="if(document.Form.Harea.rows>2)document.Form.Harea.rows-=1" style='cursor:hand'><b>缩小</b></span> <span onClick="document.Form.Harea.rows+=1" style='cursor:hand'><b>扩大</b></span><br>
 <textarea name="Harea" cols="70" rows="3"><%=Harea%></textarea></td>
 </tr>
 
 <tr bgcolor="#FFFFFF">
 <td>影片地区结束代码：</td>
 <td>&nbsp;&nbsp;输入区域： <span onClick="if(document.Form.Farea.rows>2)document.Form.Farea.rows-=1" style='cursor:hand'><b>缩小</b></span> <span onClick="document.Form.Farea.rows+=1" style='cursor:hand'><b>扩大</b></span><br>
 <textarea name="Farea" cols="70" rows="3"><%=Farea%></textarea></td>
 </tr>
 
 <tr bgcolor="#FFFFFF">
 <td>影片图片开始代码：</td>
 <td>&nbsp;&nbsp;输入区域： <span onClick="if(document.Form.Htupian.rows>2)document.Form.Htupian.rows-=1" style='cursor:hand'><b>缩小</b></span> <span onClick="document.Form.Htupian.rows+=1" style='cursor:hand'><b>扩大</b></span><br>
  <textarea name="Htupian" cols="70" rows="3" id="Htupian"><%=Htupian%></textarea></td>
 </tr>
 <tr bgcolor="#FFFFFF">
 <td>影片图片结束代码：</td>
 <td>&nbsp;&nbsp;输入区域： <span onClick="if(document.Form.Ftupian.rows>2)document.Form.Ftupian.rows-=1" style='cursor:hand'><b>缩小</b></span> <span onClick="document.Form.Ftupian.rows+=1" style='cursor:hand'><b>扩大</b></span><br>
  <textarea name="Ftupian" cols="70" rows="3" id="Ftupian"><%=Ftupian%></textarea></td>
 </tr>
   <tr bgcolor="#FFFFFF">
 <td>影片图片替换代码：<br>图片地址前后加[变量]<br>不加变量请留空</td>
 <td>&nbsp;&nbsp;输入区域： <span onClick="if(document.Form.ListPaingStr3.rows>2)document.Form.ListPaingStr3.rows-=1" style='cursor:hand'><b>缩小</b></span> <span onClick="document.Form.ListPaingStr3.rows+=1" style='cursor:hand'><b>扩大</b></span><br>
 <textarea name="ListPaingStr3" cols="70" rows="3" id="ListPaingStr3"><%=ListPaingStr3%></textarea></td>
 </tr>
 
 <tr bgcolor="#FFFFFF">
 <td>影片介绍开始代码：</td>
 <td>&nbsp;&nbsp;输入区域： <span onClick="if(document.Form.Hcontent.rows>2)document.Form.Hcontent.rows-=1" style='cursor:hand'><b>缩小</b></span> <span onClick="document.Form.Hcontent.rows+=1" style='cursor:hand'><b>扩大</b></span><br>
  <textarea name="Hcontent" cols="70" rows="3" id="Hcontent"><%=Hcontent%></textarea></td>
 </tr>
 <tr bgcolor="#FFFFFF">
 <td>影片介绍结束代码：</td>
 <td>&nbsp;&nbsp;输入区域： <span onClick="if(document.Form.Fcontent.rows>2)document.Form.Fcontent.rows-=1" style='cursor:hand'><b>缩小</b></span> <span onClick="document.Form.Fcontent.rows+=1" style='cursor:hand'><b>扩大</b></span><br>
  <textarea name="Fcontent" cols="70" rows="3" id="Fcontent"><%=Fcontent%></textarea></td>
 </tr>
 <tr bgcolor="#FFFFFF">
 <td>影片列表范围：</td>
 <td><input type="radio" value="0" name="ScopeOn" onClick="ScopeN1.style.display='none';ScopeN2.style.display='none'" <% if ScopeOn=0 then Response.Write "checked" %>>  
 关闭&nbsp;&nbsp; <input type="radio" value="1" name="ScopeOn" onClick="ScopeN1.style.display='';ScopeN2.style.display=''" <% if ScopeOn=1 then Response.Write "checked" %>> 
 开启</td>
 </tr> 
 <tr bgcolor="#FFFFFF" id="ScopeN1" <% if ScopeOn<>1 then Response.Write "style=""display:none""" %>>
 <td>播放列表开始代码：</td>
 <td>&nbsp;&nbsp;输入区域： <span onClick="if(document.Form.Hscope.rows>2)document.Form.Hscope.rows-=1" style='cursor:hand'><b>缩小</b></span> <span onClick="document.Form.Hscope.rows+=1" style='cursor:hand'><b>扩大</b></span><br>
  <textarea name="Hscope" cols="70" rows="3" id="Hscope"><%=Hscope%></textarea></td>
 </tr>
 <tr bgcolor="#FFFFFF" id="ScopeN2" <% if ScopeOn<>1 then Response.Write "style=""display:none""" %>>
 <td>播放列表结束代码：</td>
 <td>&nbsp;&nbsp;输入区域： <span onClick="if(document.Form.Fscope.rows>2)document.Form.Fscope.rows-=1" style='cursor:hand'><b>缩小</b></span> <span onClick="document.Form.Fscope.rows+=1" style='cursor:hand'><b>扩大</b></span><br>
  <textarea name="Fscope" cols="70" rows="3" id="Fscope"><%=Fscope%></textarea></td>
 </tr>
 <tr bgcolor="#FFFFFF">
 <td>播放链接开始代码：</td>
 <td>&nbsp;&nbsp;输入区域： <span onClick="if(document.Form.Hweburl.rows>2)document.Form.Hweburl.rows-=1" style='cursor:hand'><b>缩小</b></span> <span onClick="document.Form.Hweburl.rows+=1" style='cursor:hand'><b>扩大</b></span><br>
  <textarea name="Hweburl" cols="70" rows="3" id="Hweburl"><%=Hweburl%></textarea></td>
 </tr>
 <tr bgcolor="#FFFFFF">
 <td>播放链接结束代码：</td>
 <td>&nbsp;&nbsp;输入区域： <span onClick="if(document.Form.Fweburl.rows>2)document.Form.Fweburl.rows-=1" style='cursor:hand'><b>缩小</b></span> <span onClick="document.Form.Fweburl.rows+=1" style='cursor:hand'><b>扩大</b></span><br>
  <textarea name="Fweburl" cols="70" rows="3" id="Fweburl"><%=Fweburl%></textarea></td>
 </tr>
 <tr bgcolor="#FFFFFF">
 <td>特殊播放链接处理：</td>
 <td><input type="radio" value="0" name="urlType" checked="checked" onClick="Listurl2.style.display='none';Listurl3.style.display='none'" <% if urlType=0 then Response.Write "checked"%>>
  不作设置&nbsp;&nbsp;
  <input type="radio" value="1" name="urlType" onClick="Listurl2.style.display='';Listurl3.style.display=''" <% if urlType=1 then Response.Write "checked"%>>
  替换地址<br>
  <font color="red">对于使用了JavaScript:openwindow形式的连接请使用以下格式处理:<br>
  脚本连接:内容[变量] 内容 如:javaScript:OpenWnd([变量])<br>
  实际连接:内容[变量] 内容 如:play.asp?id=[变量]</font></td>
 </tr>
 <tr bgcolor="#FFFFFF" id="Listurl2" <% if urlType<>1 then Response.Write "style=""display:none""" %>>
 <td>要替换的地址：</td>
 <td>&nbsp;&nbsp;输入区域： <span onClick="if(document.Form.Rurl.rows>2)document.Form.Rurl.rows-=1" style='cursor:hand'><b>缩小</b></span> <span onClick="document.Form.Rurl.rows+=1" style='cursor:hand'><b>扩大</b></span> &nbsp;&nbsp;可用标签：<font onmouseover="getActiveText(document.Form.Rurl);" onClick="addTag('[变量]')" style="CURSOR: hand"><b>[变量]</b></font><br />
  <textarea name="Rurl" cols="70" rows="3" id="Rurl"><%=Rurl%></textarea></td>
 </tr>
 <tr bgcolor="#FFFFFF" id="Listurl3" <% if urlType<>1 then Response.Write "style=""display:none""" %>>
 <td>替换为的地址：</td>
 <td>&nbsp;&nbsp;输入区域： <span onClick="if(document.Form.Reurl.rows>2)document.Form.Reurl.rows-=1" style='cursor:hand'><b>缩小</b></span> <span onClick="document.Form.Reurl.rows+=1" style='cursor:hand'><b>扩大</b></span> &nbsp;&nbsp;可用标签：<font onmouseover="getActiveText(document.Form.Reurl);" onClick="addTag('[变量]')" style="CURSOR: hand"><b>[变量]</b></font><br />
  <textarea name="Reurl" cols="70" rows="3" id="Reurl"><%=Reurl%></textarea></td>
 </tr>
 <tr bgcolor="#FFFFFF">
 <td>影片地址开始代码：</td>
 <td>&nbsp;&nbsp;输入区域： <span onClick="if(document.Form.Hpurl.rows>2)document.Form.Hpurl.rows-=1" style='cursor:hand'><b>缩小</b></span> <span onClick="document.Form.Hpurl.rows+=1" style='cursor:hand'><b>扩大</b></span><br>
  <textarea name="Hpurl" cols="70" rows="3" id="Hpurl"><%=Hpurl%></textarea></td>
 </tr>
 <tr bgcolor="#FFFFFF">
 <td>影片地址结束代码：</td>
 <td>&nbsp;&nbsp;输入区域： <span onClick="if(document.Form.Fpurl.rows>2)document.Form.Fpurl.rows-=1" style='cursor:hand'><b>缩小</b></span> <span onClick="document.Form.Fpurl.rows+=1" style='cursor:hand'><b>扩大</b></span><br>
  <textarea name="Fpurl" cols="70" rows="3" id="Fpurl"><%=Fpurl%></textarea></td>
 </tr>

 <tr bgcolor="#FFFFFF">
 <td colspan="2"  ><input name="button" type="button" class="btn" id="button" onClick="window.location.href='javascript:history.go(-1)'" value="上一步">
  &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
  <input type="hidden" name="ID" id="ID" value="<%=ID%>">
  <input name="Submit" type="submit" class="btn" id="Submit" value="下一步"></td>
 </tr>
 </tbody>
 </form>
</table></div>
<script language="JavaScript">

function ChangeCutPara(Flag,name1,name2,name3)
{
	switch (Flag)
	{
		case 0 :
			document.getElementById(name1).style.display="block";
			document.getElementById(name2).style.display="none";
			document.getElementById(name3).style.display="none";
			break;
		case 1 :
			document.getElementById(name1).style.display="none";
			document.getElementById(name2).style.display="block";
			document.getElementById(name3).style.display="block";
			break;
		default :
			document.getElementById(name1).style.display="none";
			document.getElementById(name2).style.display="none";
			document.getElementById(name3).style.display="none";
			break;
	}
}
ChangeCutPara(<%=ClassType%>,'CollectClassN','HClassN','FClassN');
ChangeCutPara(<%=RegionType%>,'CollectRegionN','HRegionN','FRegionN');
</script>

<%
end sub

sub Copy()
dim RsCopy,rs
dim Filed
 Set RsCopy = connc.Execute("Select * from programe where ID="&Request.QueryString("ID"))
 if not RsCopy.eof then
 set rs=Server.CreateObject("ADODB.Recordset")
 Rs.Open "Select * from programe",connc,1,3
 Rs.AddNew
 For Each Filed In Rs.Fields
 if LCase(Filed.name) <> "id" then
 if LCase(Filed.name) = "collectname" then
 Rs(Filed.name) = RsCopy(Filed.name)&"-[复制]"
 else
 Rs(Filed.name) = RsCopy(Filed.name)
 end if
 end if
 Next
 Rs.Update
 Rs.MoveNext
 Set Rs= Nothing
 end if
 Set RsCopy = Nothing 
 call Admin_ShowErr("<li>复制采集栏目成功！</li>","admin_collect.asp",1) 
end sub%>
<script language="JavaScript">
currObj = "uuuu";
function getActiveText(obj)
{
 obj.focus();
 currObj = obj;
}

function addTag(ibTag)
{
 var isClose = false;
 var obj_ta = currObj;
 if (obj_ta.isTextEdit)
 {
 obj_ta.focus();
 var sel = document.selection;
 var rng = sel.createRange();
 rng.colapse;

 if((sel.type == "Text" || sel.type == "None") && rng != null)
 {
 rng.text = ibTag;
 }
 obj_ta.focus();
 return isClose;
 }
 else return false;
} 
</script>
<%call conncclose()%>
</BODY></HTML>
