<!--#include file="User_Const.asp"-->
<!--#include file="../Inc/Cl_Receive.asp"-->
<%
if ChannelID=0 then User_ShowErr("参数错误！")
if Not Cl.TrueChannelPurview_U(5,ChannelID) then User_ShowErr("<li>您无此操作权限！</li>")
const MaxPerPage=20
dim ManageType,Action
'=====================================
dim keyword,strField
dim rsList,sPath
dim InfoID,arrInfoID,rsMove
dim ClassID,Passed,SpecialID,SpecialName
dim tClass,ClassName,RootID,ParentID,Depth,ParentPath,Child,arrChildID
'=============================================
dim ArticleID,Title,Prefixion,TitleIntact
Dim Content,Author,CopyFrom,UpdateTime,Hits
dim DefaultPicUrl,OnTop,Hot,Elite,arrUploadFiles
dim TitleFontColor,TitleFontType,AuthorName,AuthorEmail,CopyFromName,CopyFromUrl
Dim PaginationType,ReadLevel,ReadPoint,ReadMoney,Stars,MaxCharPerPage,NowCreate,Editor
dim IsReceive,ReceiveUser,AutoReceiveTime,ReceiveType,ArticleIntro,IsLink,LinkUrl
dim sMaxLimit,sAddPoint,sAddIsChk,UploadFiles,IsTruePurview,IsTruePurview_P
dim BackPoint,BackPointRate,BackMoney,BackMoneyRate
'=============================================
Cl.GetChannelSetting(ChannelID)
Action		= Trim(request("Action"))

Select Case Action
Case "Add"
	AddMain
Case "Modify"
	ModifyMain
Case "SaveAdd", "SaveModify"
	DoSaveRecord
Case "Show"
	ShowInfoMain
Case Else
	ManageMain
End Select

Footer

Sub ManageMain()
	ManageType	= Trim(request("ManageType"))
	ClassID		= Cl.ChkClng(request("ClassID"))
	SpecialID	= Cl.ChkClng(request("SpecialID"))
	'=============
	OnTop		= Cl.ChkCBool(request("OnTop"))
	Hot			= Cl.ChkCBool(request("Hot"))
	Elite		= Cl.ChkCBool(request("Elite"))
	'=============
	keyword		= Trim(request("keyword"))
	'Property	= Trim(request("Property"))
	strField	= Trim(request("Field"))
	Passed		= Trim(request("Passed"))
	CurrentPage	= Cl.ChkClng(request("page"))
	if keyword="" then keyword="关键字"
	FileName	= "User_Article.Asp?ChannelID="&ChannelID&"&Action="&Action&""
	if ManageType="MyInfo" then
		FileName=FileName & "&ManageType=" & ManageType
	'else
	'	if Not Cl.TrueChannelPurview_U(3,ChannelID) then User_ShowErr("<li>您无此操作权限！</li>")
	end if
	'======================1
	strFileName	= FileName & "&ClassID=" & ClassID & "&SpecialID=" & SpecialID & "&Field=" & strField & "&keyword=" & keyword
	'======================1
	if Passed="" then
		Passed="All"
		Select Case Action
		Case "Check"
			Passed=FalseType
		Case "Make"
			Passed=TrueType
		Case ""
			if ManageType<>"MyInfo" then Passed=TrueType
		End Select
	end if
	if ClassID>0 then
		set tClass=Cl.Execute("select ClassName,RootID,ParentID,Depth,ParentPath,Child,arrChildID From Cl_Class where ChannelID="&ChannelID&" and ClassID=" & ClassID)
		if tClass.bof and tClass.eof then
			tClass.Close :Set tClass=Nothing
			User_ShowErr("<br><li>找不到指定的栏目</li>")
		else
			ClassName=tClass(0):RootID=tClass(1):ParentID=tClass(2)
			Depth=tClass(3):ParentPath=tClass(4):Child=tClass(5):arrChildID=tClass(6)
			tClass.Close :Set tClass=Nothing
			If Cint(Cl.User_Purview(0)) > 1 and ManageType<>"MyInfo" then
				Dim sTr,sTPurview
				sTPurview=False
				sTr=Split(ParentPath & "," & ClassID,",")
				if Action="Check" then
					if Cl.TrueChannelPurview_U(2,ChannelID) then
						sTPurview=True
					else
						for i=1 to Ubound(sTr)
							sTPurview=Cl.TrueClassPurview_U(2,ChannelID,sTr(i))
							if sTPurview=True then Exit For
						Next
					end if
				Else
					if Cl.TrueChannelPurview_U(1,ChannelID) then
						sTPurview=True
					else
						for i=1 to Ubound(sTr)
							sTPurview=Cl.TrueClassPurview_U(1,ChannelID,sTr(i))
							if sTPurview=True then Exit For
						Next
					end if
				End if
				If sTPurview=False then User_ShowErr("<br><li>找不到指定的栏目或您无此操作权限</li>")
			End if
			if ParentID>0 then
				dim sqlPath,rsPath
				sqlPath="select ClassID,ClassName From Cl_Class where ChannelID="&ChannelID&" and ClassID in (" & ParentPath & ") order by Depth"
				set rsPath=Cl.Execute(sqlPath)
				if Not rsPath.eof then
					sqlPath=rsPath.GetRows(-1)
					for i=0 to Ubound(sqlPath,2)
						sPath = sPath & "<a href=""" & FileName & "&ClassID=" & sqlPath(0,i) & """><font color=#0000ff>" & sqlPath(1,i) & "</font></a>&nbsp;&gt;&gt;&nbsp;"
					Next
					sqlPath=Empty
				End if
				rsPath.Close:Set rsPath=Nothing
			end if
			sPath = sPath & "<a href=""" & FileName & "&ClassID=" & ClassID & """><font color=#0000ff>" & ClassName & "</font></a>"
		end if
	end if
%>
<html>
<head>
<title>文章管理</title>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<link rel="stylesheet" type="text/css" href="../Skins/User_Style.Css">
<script Language="JavaScript" src="../Inc/Js/admin.js"></script>
<script language=javascript>
function unselectall()
{
    if(document.myform.chkAll.checked){
	document.myform.chkAll.checked = document.myform.chkAll.checked&0;
    } 	
}

function CheckAll(form)
  {
  for (var i=0;i<form.elements.length;i++)
    {
    var e = form.elements[i];
    if (e.Name != "chkAll"&&e.disabled==false)
       e.checked = form.chkAll.checked;
    }
  }
function ConfirmDel()
{
	switch(document.myform.Action.value){
	case "Del":
		if(confirm("确定要删除选中的<%=Cl.Channel_Setting(2)%>吗？本操作将把选中的<%=Cl.Channel_Setting(2)%>移到回收站中。必要时您可从回收站中恢复！"))
		    return true;
		else
			return false;
	case "MoveMore":
		document.myform.action="User_InfoMove.asp";
		return true;
	case "MoveToSpecial":
		document.myform.action="User_InfoMove.asp";
		if(confirm("确定要将选中的<%=Cl.Channel_Setting(2)%>移动到指定的专题吗？"))
		    return true;
		else
			return false;
	case "SetPassed":
		document.myform.action="User_Property.asp";
		return true;
	case "CancelPassed":
		document.myform.action="User_Property.asp";
		return true;
	case "DelFromSpecial":
		document.myform.action="User_InfoDel.asp";
		if(confirm("确定要选中的<%=Cl.Channel_Setting(2)%>的专题吗？"))
		    return true;
		else
			return false;
	case "ConfirmDel":
		document.myform.action="User_InfoDel.asp";
		if(confirm("确定要将选中的<%=Cl.Channel_Setting(2)%>彻底删除吗？本操作将不可恢复！"))
		    return true;
		else
			return false;
	case "ClearRecyclebin":
		document.myform.action="User_InfoDel.asp";
		if(confirm("确定要清空回收站吗？本操作将不可恢复！"))
		    return true;
		else
			return false;
	case "Restore":
		document.myform.action="User_InfoDel.asp";
		if(confirm("确定要还原选中的<%=Cl.Channel_Setting(2)%>吗？"))
		    return true;
		else
			return false;
	case "RestoreAll":
		document.myform.action="User_InfoDel.asp";
		if(confirm("确定要还原所有<%=Cl.Channel_Setting(2)%>吗？"))
		    return true;
		else
			return false;
	case "CreateArticle":
		document.myform.action="User_Create_Article.asp";
		if(confirm("确定要生成选中<%=Cl.Channel_Setting(2)%>吗？"))
		    return true;
		else
			return false;
	case "CreateArticleAll":
		document.myform.action="User_Create_Article.asp";
		if(confirm("确定要生成所有<%=Cl.Channel_Setting(2)%>吗？此操作可能将消耗服务器资源很大！"))
		    return true;
		else
			return false;
	case "DelArticleHTML":
		document.myform.action="User_Create_Article.asp";
		if(confirm("确定要生成选中<%=Cl.Channel_Setting(2)%>的HTML文件吗？"))
		    return true;
		else
			return false;
	case "DelArticleHTMLAll":
		document.myform.action="User_Create_Article.asp";
		if(confirm("确定要删除所有<%=Cl.Channel_Setting(2)%>的HTML文件吗？"))
		    return true;
		else
			return false;
	default:
		return false;
	}
	return true;
}

</script>
</head>
<body leftmargin="0" topmargin="0" marginwidth="0" marginheight="0">
<table width="100%" border="0" align="center" cellpadding="2" cellspacing="1" class="border">
  <tr class="title"> 
    <td height="22" colspan="2"  align="center"><strong><%=Cl.Channel_Setting(2)%>管理</strong></td>
  </tr>
  <tr class="tdbg"> 
    <td width="70" height="30" ><strong>管理导航：</strong></td>
    <td><a href="User_Article.Asp?ChannelID=<%=ChannelID%>"><%=Cl.Channel_Setting(2)%>管理首页</a>&nbsp;|&nbsp;<a href="User_Article.Asp?Action=Add&ChannelID=<%=ChannelID%>">添加<%=Cl.Channel_Setting(2)%></a>&nbsp;|&nbsp;<a href="User_Article.Asp?ChannelID=<%=ChannelID%>&Action=Check">审核<%=Cl.Channel_Setting(2)%></a>&nbsp;|&nbsp;<a href="User_Comment.asp?ChannelID=<%=ChannelID%>" target=main><%=Cl.Channel_Setting(2)%>评论管理</a>&nbsp;|&nbsp;<a href="User_Article.Asp?ChannelID=<%=ChannelID%>&Action=Special" target=main>专题管理</a>&nbsp;|&nbsp;<a href="User_Article.Asp?ChannelID=<%=ChannelID%>&Action=RecycleBin" target=main>回收站管理</a>
	</td>
  </tr>
<form name="FormProperty" method="Post" action="<%=strFileName%>">
  <tr class="tdbg"> 
    <td width="70" height="30"><strong><%=Cl.Channel_Setting(2)%>选项：</strong></td>
    <td>
	<a href="<%=strFileName%>&Passed=All"><%
	if Passed<>FalseType and Passed<>TrueType then
	%><font color=red><b>所有<%=Cl.Channel_Setting(2)%></b></font><%
	else
	%>所有<%=Cl.Channel_Setting(2)%><%
	end if%></a>&nbsp;|&nbsp;<a href="<%=strFileName%>&Passed=<%=FalseType%>"><%
	if Passed=FalseType then
	%><font color=red><b>未审核<%=Cl.Channel_Setting(2)%></b></font><%
	else
	%>未审核<%=Cl.Channel_Setting(2)%><%
	end if
	%></a>&nbsp;|&nbsp;<a href="<%=strFileName%>&Passed=<%=TrueType%>"><%
	if Passed=TrueType then
	%><font color=red><b>已审核<%=Cl.Channel_Setting(2)%></b></font><%
	else
	%>已审核<%=Cl.Channel_Setting(2)%><%
	end if%></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
	<input name="OnTop" type="checkbox" onclick="submit()" value="True" <%if OnTop then%>checked<%end if%>>
	固顶<%=Cl.Channel_Setting(2)%>&nbsp;&nbsp;&nbsp;&nbsp;
	<input name="Elite" type="checkbox" onclick="submit()" value="True" <%if Elite then%>checked<%end if%>>
	推荐<%=Cl.Channel_Setting(2)%>&nbsp;&nbsp;&nbsp;&nbsp;
	<input name="Hot" type="checkbox" onclick="submit()" value="True" <%if Hot then%>checked<%end if%>>
	热门<%=Cl.Channel_Setting(2)%>
	</td>
  </tr>
  </form>
  <tr class="tdbg">
    <td width="70"><strong>高级搜索：</strong></td>
    <td>
	<table border=0 cellpadding=0 cellspacing=0>
	<form method="Post" name="SearchForm" action="<%=FileName%>">
	<tr><td height=28 align="center">
		<select name="Field" size="1" ID="Field">
		<option value="ID"><%=Cl.Channel_Setting(2)%>ID</option>
		<option value="Title" selected><%=Cl.Channel_Setting(2)%>标题</option>
		<option value="Keyword">关 键 字</option>
		<option value="Intro"><%=Cl.Channel_Setting(2)%>简介</option>
		<option value="CopyFrom"><%=Cl.Channel_Setting(2)%>来源</option>
		<option value="Author"><%=Cl.Channel_Setting(2)%>作者</option>
		<option value="Editor">添加用户</option>
		<option value="Censor">审核用户</option>
		<option value="Point"><%=Cl.Channel_Setting(2)%><%=Cl.Web_Setting(28)%></option>
		</select>&nbsp;
		<select name="ClassID" ID="ClassID">
		<option value="">所有栏目</option>
		<%=ShowClass_Option(ChannelID,0,1,3)%>
		</select>&nbsp;
		<select name="SpecialID" ID="SpecialID">
		<%=ShowSpecial_Option(ChannelID,0,1)%>
		</select>&nbsp;
		<select name="Passed" ID="Passed">
		<option value="All">资料选项</option>
		<option value="<%=FalseType%>">未审<%=Cl.Channel_Setting(2)%></option>
		<option value="<%=TrueType%>">已审<%=Cl.Channel_Setting(2)%></option>
		</select>&nbsp;
		<input name="OnTop" type="checkbox" value="True" <%if OnTop then%>checked<%end if%>>顶&nbsp;<input name="Elite" type="checkbox" value="True" <%if Elite then%>checked<%end if%>>荐&nbsp;<input name="Hot" type="checkbox" value="True" <%if Hot then%>checked<%end if%>>热&nbsp;
		<input type="text" name="keyword"  size="20" value="<%=keyword%>" maxlength="50" onFocus="this.select();">&nbsp;
		<input type="submit" name="Submit"  value=" 搜索 "></td>
	</tr>
	</form></table>
    </td>
  </tr>
<%if Action="Special" then%>
  <tr class="tdbg"> 
    <td width="70" height="30"><strong>专题选项：</strong></td>
    <td>
	<%if SpecialID=0 then
	%>
	<a href="<%=FileName%>&SpecialID=0&Passed=<%=Passed%>"><font color=red><b>所有专题</b></font></a><%
	else
	%>
	<a href="<%=FileName%>&SpecialID=0&Passed=<%=Passed%>">所有专题</a><%
	end if
	%>&nbsp;|&nbsp;<%=ShowRootSpecial(ChannelID,SpecialID)%>
	</td>
  </tr>
<%else%>
  <tr class="tdbg"> 
    <td width="70" height="30"><strong>栏目选项：</strong></td>
    <td>
	<%if ClassID=0 then%>
	<a href="<%=FileName%>&ClassID=0&Passed=<%=Passed%>"><font color=red><b>所有栏目</b></font></a><%
	else
	%>
	<a href="<%=FileName%>&ClassID=0&Passed=<%=Passed%>">所有栏目</a><%
	end if
	%>&nbsp;|&nbsp;<%=ShowRootClass(ChannelID,RootID)%>
	</td>
  </tr>
<%
end if
if ParentID>0 or Child>0 then
%>
  <tr class="tdbg">
    <td width="70" height="30"><strong>子 栏 目：</strong></td>
    <td><%=sPath%><%=ShowManageChild(ChannelID,ClassID)%></td>
  </tr>
<%
end if
%>
</table>
<script LANGUAGE="JavaScript">
CheckSel('Field','<%=strField%>');
CheckSel('ClassID','<%=ClassID%>');
CheckSel('SpecialID','<%=SpecialID%>');
CheckSel('Passed','<%=Passed%>');
</script>
<%
	sql="select A.ArticleID,A.ClassID,C.ClassName,A.Title,A.Keyword,A.Author,A.CopyFrom,A.UpdateTime,A.Editor,A.Hits,A.OnTop,A.Hot,A.Elite,A.Passed,A.Prefixion,A.Stars,A.PaginationType,A.ReadLevel,A.ReadPoint,A.TitleFontColor,A.TitleFontType,A.IsHtml,A.HtmlFileUrl,A.Receive,A.ReceiveUser,A.NotReceiveUser,A.Received,A.AutoReceiveTime,A.ReceiveType,A.IsLink,A.NoPass,A.Censor,A.CensorTime from Cl_Article A Inner Join Cl_Class C On A.ClassID=C.ClassID where A.ChannelID="&ChannelID&""
	Select Case Action
	Case "RecycleBin"
		sql=sql & " and (A.NoPass=True or A.Deleted=True)"
	Case "NoPass"
		sql=sql & " and A.NoPass=True and A.Deleted=False"
	Case else
		sql=sql & " and A.NoPass=False and A.Deleted=False"
	end Select
	if Passed<>"All" then sql=sql & " and A.Passed=" & Passed
	if ClassID>0 then
		if Child>0 then
			sql=sql & " and A.ClassID in (" & arrChildID & ")"
		else
			sql=sql & " and A.ClassID=" & ClassID
		end if
	elseif Not Cl.TrueChannelPurview_U(2,ChannelID) and ManageType<>"MyInfo" then
		dim arrIDStr,TempID
		arrIDStr=","
		if Action="Check" then
			if Cl.User_Info(39)<>"" then
				TempID = Split(Cl.User_Info(39),",")
				for i=0 to ubound(TempID)
					set tClass=Cl.Execute("select arrChildID From Cl_Class where ChannelID="&ChannelID&" and ClassID=" & Cl.ChkClng(TempID(i)))
					if Not (tClass.bof and tClass.eof) then
						arrIDStr=arrIDStr & "," & tClass(0)
					End if
					tClass.Close : Set tClass=Nothing
				Next
			end if
			if Cl.User_Info(38)<>"" then
				TempID = Split(Cl.User_Info(38),",")
				for i=0 to ubound(TempID)
					set tClass=Cl.Execute("select arrChildID From Cl_Class where ChannelID="&ChannelID&" and ClassID=" & Cl.ChkClng(TempID(i)))
					if Not (tClass.bof and tClass.eof) then
						arrIDStr=arrIDStr & "," & tClass(0)
					End if
					tClass.Close : Set tClass=Nothing
				Next
			End if
		else
			if Cl.User_Info(39)<>"" then
				TempID = Split(Cl.User_Info(39),",")
				for i=0 to ubound(TempID)
					set tClass=Cl.Execute("select arrChildID From Cl_Class where ChannelID="&ChannelID&" and ClassID=" & Cl.ChkClng(TempID(i)))
					if Not (tClass.bof and tClass.eof) then
						arrIDStr=arrIDStr & "," & tClass(0)
					End if
					tClass.Close : Set tClass=Nothing
				Next
			end if
		end if
		TempID=Empty
		if arrIDStr="," then
			sql=sql & " and A.ClassID=0"
		else
			sql=sql & " and A.ClassID in (" & Replace(arrIDStr,",,","") & ")"
		end if
	end if
	if Action="Special" then
		if SpecialID>0 then
			sql=sql & " and A.SpecialID Like '%," & SpecialID & ",%'"
		else
			sql=sql & " and A.SpecialID<>'0'"
		end if
	end if
	if ManageType="MyInfo" then
		sql=sql & " and A.Editor='" & Cl.User_Info(5) & "' "
	else
		if keyword<>"" and keyword<>"关键字" then
			keyword = Cl.ReplaceBadChar(keyword&"")
			select case strField
			case "ID"
				sql=sql & " and A.ArticleID = "&Cl.ChkClng(keyword)&" "
			case "Title"
				sql=sql & " and A.Title like '%" & keyword & "%' "
			case "Keyword"
				sql=sql & " and A.Keyword like '%" & keyword & "%' "
			case "Intro"
				sql=sql & " and A.Content like '%" & keyword & "%' "
			case "CopyFrom"
				sql=sql & " and A.CopyFrom like '%" & keyword & "%' "
			case "Author"
				sql=sql & " and A.Author like '%" & keyword & "%' "
			case "Editor"
				sql=sql & " and A.Editor='" & keyword & "' "
			case "Censor"
				sql=sql & " and A.Censor='" & keyword & "' "
			case "Point"
				sql=sql & " and A.ReadPoint <= "&Cl.ChkClng(keyword)&" "
			case else
				sql=sql & " and A.Title like '%" & keyword & "%' "
			end select
			'=================
			Set rsMove=Cl.Execute(sql & " order by A.UpDateTime desc,A.ArticleID desc")
			if Not rsMove.Eof then
				Dim Tvalue,Ti
				Tvalue=rsMove.GetRows(-1)
				arrInfoID=Tvalue(0,0)
				For Ti=1 To Ubound(Tvalue,2)
					arrInfoID=arrInfoID&","&Tvalue(0,Ti)
				Next
			end if
			Set rsMove=Nothing
			'=================
		end if
	end if
	'==================
	If OnTop then sql=sql & " and A.ontop=True "
	If Elite then sql=sql & " and A.elite=True "
	If Hot then sql=sql & " and A.hot=True "
	'===================
	sql=sql & " order by A.UpDateTime desc,A.ArticleID desc"
%>
<table width="100%" border="0" align="center" cellpadding="0" cellspacing="0">
  <tr> 
    <td height="22" align="right">
	<select name='JumpClass' id="JumpClass" onchange="if(this.options[this.selectedIndex].value!=''){location='<%=FileName & "&ClassID="%>'+this.options[this.selectedIndex].value;}">
      <option value='' selected>跳转栏目至…</option>
	  <%=ShowClass_Option(ChannelID,0,2,1)%>
	</select>
    &nbsp;</td>
  </tr>
</table>
<%
	Set rsList= Server.CreateObject("ADODB.Recordset")
	OpenConn : rsList.open sql,Conn,1,1
	if rsList.eof and rsList.bof then
		TotalPut=0
		if Child=0 then
			response.write "<p align='center'><br>没有任何"&Cl.Channel_Setting(2)&"！</p>"
		else
			response.write "<p align='center'><br>此栏目下没有任何"&Cl.Channel_Setting(2)&"！</p>"
		end if
		rsList.close:set rsList=Nothing
	else
		TotalPut = rsList.recordcount
		if (TotalPut mod MaxPerPage)=0 then
			TotalPages = TotalPut \ MaxPerPage
		else
			TotalPages = TotalPut \ MaxPerPage + 1
		end if
		if CurrentPage > TotalPages then CurrentPage=TotalPages
		if CurrentPage > 1 then
			rsList.move (CurrentPage-1)*MaxPerPage
		else
			CurrentPage=1
		end if
		SQL=rsList.GetRows(MaxPerPage)
		rsList.close:set rsList=Nothing
		ShowContent
		'==================
		Response.write Cl.ShowPage(strFileName & "&OnTop="&OnTop&"&Hot="&Hot&"&Elite="&Elite&"&Passed="&Passed,TotalPut,MaxPerPage,Cl.Channel_Setting(3),Cl.Channel_Setting(2))
		'==================
	end if
%>
<br>
<br><b>说明：</b><br>&nbsp;&nbsp;&nbsp;&nbsp;
属性中的各项含义：<font color=blue>顶</font>---固顶，<font color=red>热</font>---热门，<font color=green>荐</font>---推荐，<font color=blue>图</font>---图片，<font color=blue>H</font>---已生成HTML文件，<font color=red>转</font>---转向连接文章
<br><br>
<%
SQL=Empty
End Sub

Sub ShowContent()
   	dim TitleStr
%>
	<table class="border" border="0" cellspacing="1" cellpadding="0" align="center">
	<form name="myform" method="Get" action="User_InfoDel.asp" onsubmit="return ConfirmDel();">
          <tr class="title" height="22"> 
            <td height="22" width="30" align="center"><strong>选中</strong></td>
            <td width="40" align="center"  height="22"><strong>ID</strong></td>
            <td align="center"><strong>标题</strong></td>
            <td width="80" align="center"><strong>添加人</strong></td>
            <td width="80" align="center"><strong>审核人</strong></td>
            <td width="40" align="center"><strong>点击数</strong></td>
            <td width="80" align="center"><strong><%=Cl.Channel_Setting(2)%>属性</strong></td>
            <td width="150" align="center"><strong>操作</strong></td>
          </tr>
          <%
		  for i=0 to Ubound(SQL,2)
		  InfoID=SQL(0,i)
		  %>
          <tr class="tdbg" onMouseOut="this.className='tdbg'" onMouseOver="this.className='tdbg2'"> 
            <td width="30" align="center"><input name="InfoID" type="checkbox" onclick="unselectall()" id="InfoID" value="<%=InfoID%>"></td>
            <td width="40" align="center"><%=InfoID%></td>
            <td> <%
			TitleStr=Cl.GetTitleFont(SQL(3,i),SQL(20,i))
			TitleStr=Cl.FormatColor(TitleStr,SQL(19,i))
			if Clng(SQL(1,i))<>ClassID then
				response.write "<a href='"&FileName&"&ClassID=" & SQL(1,i) & "'>[" & SQL(2,i) & "]</a>&nbsp;"
			end if
			if Not (IsNull(SQL(14,i)) or SQL(14,i)="") then
				response.write "<font color=blue>"&SQL(14,i)&"</font>"
			end if
			response.write "<a href='User_Article.Asp?Action=Show&ChannelID="&ChannelID&"&ArticleID=" & InfoID & "' title='标    题：" & SQL(3,i) & vbcrlf & "作    者：" & SQL(5,i) & vbcrlf & "转 贴 自：" & SQL(6,i) & vbcrlf & "更新时间：" & SQL(7,i) & vbcrlf & "点 击 数：" & SQL(9,i) & vbcrlf & "关 键 字：" & SQL(4,i) & vbcrlf & "推荐等级：" & String(SQL(15,i),"★")
			response.write vbcrlf & "分页方式："
			Select Case SQL(16,i)
			Case 0 : response.write "不分页"
			Case 1 : response.write "自动分页"
			Case 2 : response.write "手动分页"
			End Select
			response.write vbcrlf & "阅读等级：" & Cl.GetUserGroupName(SQL(17,i))
			response.write vbcrlf & "阅读"&Cl.Web_Setting(28)&"：" & SQL(18,i)
			response.write "'>" & TitleStr & "</a>"
			%></td>
			<!------------------------>
            <td width="80" align="center"><a href="<%=FileName%>&Passed=All&Field=Editor&Keyword=<%=SQL(8,i)%>" title="点击将查看此用户添加的所有<%=Cl.Channel_Setting(2)%>"><%=SQL(8,i)%></a><br>(<font color=#0000ff><%=formatdatetime(SQL(7,i),2)%></font>)</td>
            <td width="80" align="center"><%
			if SQL(13,i)=True then
				response.write "<a href='"&FileName&"&Passed=All&Field=Censor&Keyword="&SQL(31,i)&"' title='点击将查看此用户审核的所有"&Cl.Channel_Setting(2)&"'>" & SQL(31,i) & "</a><br>(<font color=#0000ff>" & SQL(32,i) & "</font>)"
			else
				if SQL(30,i)=False then
				response.write "<a href='Admin_Property.asp?ChannelID="&ChannelID&"&Action=SetPassed&InfoID=" & SQL(0,i) & "' title='点击审核通过'><font color=""#ff0033"">审核通过</font></a>&nbsp;<a href='User_NoPass.asp?ChannelID="&ChannelID&"&InfoID=" & SQL(0,i) & "'>退回</a>"
				else
				response.write "<font color=""#ff0033"">已退回</font>("&SQL(21,i)&")"
				end if
			end if%></td>
			<!------------------------>
            <td width="40" align="center"><%= SQL(9,i) %></td>
            <td width="80" align="center"> <%
			if SQL(23,i)=True then
				response.Write "<span title=""要签收用户："&SQL(24,i)& VbcrLf &"已签收用户："&SQL(26,i)& VbcrLf &"未签收用户："&SQL(25,i)& VbcrLf &"自动签收时间："&SQL(27,i)&"""><font color=""#FF00FF"">签收</font> "
				if SQL(28,i)=1 then
					response.Write "(<font color=""#0000FF"">专属</font>)"
				else
					response.Write "(公众)"
				end if
				response.Write "</span><br>"
			end if
			if SQL(10,i)=True then
				response.Write "<font color=blue>顶</font> "
			else
				response.write "&nbsp;&nbsp;&nbsp;"
			end if
			if SQL(11,i)=True then
				response.write "<font color=red>热</font> "
			else
				response.write "&nbsp;&nbsp;&nbsp;"
			end if
			if SQL(12,i)=True then
				response.write "<font color=green>荐</font> "
			else
				response.write "&nbsp;&nbsp;&nbsp;"
			end if
			if SQL(21,i)=True then
				response.write "<font color=blue>H</font>"
			else
				if SQL(29,i)=True then
				response.write "<font color=red>转</font>"
				else
				response.write "&nbsp;&nbsp;"
				end if
			end if
			%> </td>
            <td width="150" align="left"> &nbsp;<% Call ManegeOption() %></td>
          </tr>
          <%
	Next
%>
  <tr class="tdbg">
    <td colspan=2 height="30"><input name="chkAll" type="checkbox" id="chkAll" onclick=CheckAll(this.form) value="checkbox">选中所有</td>
    <td colspan=6><% Call ManegeOptionBottom() %></td>
  </tr>
</form>
</table>
<%

	if KeyWord<>"" and arrInfoID<>"" then
		Response.write "<form name=""myform2"" method=""Post"" action=""User_InfoDel.asp"" onsubmit=""return ConfirmDel2();"">"
		Response.write "<input type=""hidden"" name=""Action"" Value=""MoveToClass"">"
		Response.write "搜索结果操作：<input name=""submit"" type=""submit"" value=""删除"" onClick=""document.myform.Action.Value='Del'"">"
		Response.write "&nbsp;&nbsp; <input type=""submit"" name=""Submit"" value=""移动到栏目："" onClick=""document.myform.Action.value='MoveToClass'"">"
		Response.write "<select name=""TargetClassID"">"&ShowClass_Option(ChannelID,ClassID,2,1)&"</select>"
		Response.write "&nbsp;&nbsp; <input type=""submit"" name=""Submit"" value=""移动到专题："" onClick=""document.myform.Action.value='MoveToSpecial'"">"
		Response.write "<select name=""SpecialID"">"&ShowSpecial_Option(ChannelID,SpecialID,1)&"</select>"
		Response.write "<input type=""hidden"" name=""InfoID"" Value="""&arrInfoID&""">"
		Response.write "</form>"
		 %>
<script language=javascript>
function ConfirmDel2()
{
	switch(document.myform2.Action.value){
	case "Del":
		document.myform2.action="User_InfoDel.asp";	if(confirm("确定要删除选中的<%=Cl.Channel_Setting(2)%>吗？本操作将把选中的<%=Cl.Channel_Setting(2)%>移到回收站中。必要时您可从回收站中恢复！"))
		    return true;
		else
			return false;
	case "MoveMore":
		document.myform2.action="User_InfoMove.asp";
		if(confirm("确定要将选中的<%=Cl.Channel_Setting(2)%>移动到指定的栏目吗？"))
		    return true;
		else
			return false;
	case "MoveToSpecial":
		document.myform2.action="User_InfoMove.asp";
		if(confirm("确定要将选中的<%=Cl.Channel_Setting(2)%>移动到指定的专题吗？"))
		    return true;
		else
			return false;
	default:
		return false;
	}
	return true;
}

</script>
		 <%
		'Response.write arrInfoID
	end if
End Sub

Sub ManegeOption()
	Select Case Action
	Case "Check"
	  	If SQL(13,i)=False Then
        	response.write "<a href='User_Property.asp?ChannelID="&ChannelID&"&Action=SetPassed&InfoID=" & InfoID & "'>通过审核</a>"
			response.write "&nbsp;<a href='User_NoPass.asp?ChannelID="&ChannelID&"&InfoID=" & InfoID & "'>退回</a>"
		Else
	        response.write "<a href='User_Property.asp?ChannelID="&ChannelID&"&Action=CancelPassed&InfoID=" & InfoID & "'>取消通过</a>"
      	End If
		response.write "&nbsp;&nbsp;<a href='User_Article.Asp?Action=Modify&ChannelID="&ChannelID&"&ArticleID=" & InfoID &"'>修改</a>"
		response.write "&nbsp;<a href='User_Property.asp?ChannelID="&ChannelID&"&Action=deleted&InfoID=" & InfoID & "' onclick=""return confirm('确定要删除此"&Cl.Channel_Setting(2)&"吗？本操作将不可恢复！');"">删除</a>"
	Case "RecycleBin"
		response.write "<a href=""User_InfoDel.asp?Action=ConfirmDel&ChannelID="&ChannelID&"&InfoID="&InfoID&""" onclick=""return confirm('确定要彻底删除此"&Cl.Channel_Setting(2)&"吗？本操作将不可恢复！');"">彻底删除</a> &nbsp;&nbsp; <a href=""User_InfoDel.asp?Action=Restore&ChannelID="&ChannelID&"&InfoID="&InfoID&""">还原</a>"
	'Case "Special"

	Case "Make"
		if SQL(13,i)=True then
			response.write "<a href='User_Create_Article.asp?ChannelID="&ChannelID&"&Action=CreateArticle&InfoID=" & InfoID & "'>生成HTML</a>&nbsp;"
		else
			response.write "生成HTML&nbsp; "
		end if
		if SQL(21,i)=True then	
			response.write "<a href='User_Create_Article.asp?ChannelID="&ChannelID&"&Action=DelArticleHTML&InfoID=" & InfoID & "'>删除HTML</a>&nbsp;"
			response.write "<a href='" & Cl.WebDir & SQL(22,i) & "' target='_blank'>浏览HTML</a>&nbsp;"
		end if
	Case Else
		response.write "<a href='User_Article.Asp?Action=Modify&ChannelID="&ChannelID&"&ArticleID=" & InfoID &"'>改</a>&nbsp;"
		response.write "<a href='User_InfoDel.asp?ChannelID="&ChannelID&"&InfoID=" & InfoID & "&Action=Del' onclick='return ConfirmDel();'>删</a>&nbsp;"
		'if Clng(Cl.User_Purview(0))=1 or Clng(Cl.User_Purview(1))<=1 then
			response.write "<a href='User_InfoMove.asp?ChannelID="&ChannelID&"&InfoID=" & InfoID & "'>移</a>&nbsp;"
		'end if
		if SQL(10,i)=False then	
			response.write "<a href='User_Property.asp?ChannelID="&ChannelID&"&InfoID=" & InfoID & "&Action=SetOnTop'>固顶</a>&nbsp;"
		else
			response.write "<a href='User_Property.asp?ChannelID="&ChannelID&"&InfoID=" & InfoID & "&Action=CancelOnTop'>解固</a>&nbsp;"
		end if
		if SQL(12,i)=False then	
			response.write "<a href='User_Property.asp?ChannelID="&ChannelID&"&InfoID=" & InfoID & "&Action=SetElite'>设为推荐</a>"
		else
			response.write "<a href='User_Property.asp?ChannelID="&ChannelID&"&InfoID=" & InfoID & "&Action=CancelElite'>取消推荐</a>"
		end if
	End Select
End Sub

Sub ManegeOptionBottom()
	Response.write "<input name=""ChannelID"" type=""hidden"" id=""ChannelID"" value="""&ChannelID&""">"
	Response.write "<input name=""Action"" type=""hidden"" id=""Action"" value=""Del"">"
	Select Case Action
	Case "Check"
		if Passed=FalseType then
			Response.write "<input name=""submit"" type=""submit"" value=""审核选定的"&Cl.Channel_Setting(2)&""" onClick=""document.myform.Action.value='SetPassed'"">"
			Response.write "&nbsp;&nbsp;<input name=""submit"" type=""submit"" value=""删除选定的"&Cl.Channel_Setting(2)&""" onClick=""document.myform.Action.value='Del'"">"
		else
			Response.write "<input name=""submit"" type=""submit"" value=""取消审核选定的"&Cl.Channel_Setting(2)&""" onClick=""document.myform.Action.value='CancelPassed'"">"
			Response.write "&nbsp;&nbsp;<input name=""submit"" type=""submit"" value=""删除选定的"&Cl.Channel_Setting(2)&""" onClick=""document.myform.Action.value='Del'"">"
		end if
	Case "RecycleBin"
		Response.write "<input name=""submit1"" type=""submit"" id=""submit1"" onClick=""document.myform.Action.value='ConfirmDel'"" value=""彻底删除选定的"&Cl.Channel_Setting(2)&""">"
		Response.write "<input type=""submit"" name=""Submit2"" value=""清空回收站""  onClick=""document.myform.Action.value='ClearRecyclebin'"">"
		Response.write "&nbsp;&nbsp;&nbsp;&nbsp;<input name=""Submit3"" type=""submit"" id=""Submit3""  onClick=""document.myform.Action.value='Restore'"" value=""还原选定的"&Cl.Channel_Setting(2)&""">"
		Response.write "<input name=""Submit4"" type=""submit"" id=""Submit4"" onClick=""document.myform.Action.value='RestoreAll'"" value=""还原所有"&Cl.Channel_Setting(2)&""">"
	Case "Special"
		Response.write "<input name=""submit"" type=""submit"" value=""将选定的"&Cl.Channel_Setting(2)&"从所属专题中删除"" onClick=""document.myform.Action.value='DelFromSpecial'"">"
		Response.write "&nbsp;&nbsp;&nbsp;&nbsp; <input type=""submit"" name=""Submit"" value=""将选定的"&Cl.Channel_Setting(2)&"移动到"" onClick=""document.myform.Action.value='MoveToSpecial'"">"
		Response.write "<select name=""SpecialID"">"&ShowSpecial_Option(ChannelID,SpecialID,1)&"</select>"
	Case "Make"
		'Response.write "<br>"
		Response.write "<input name=""submit1"" type=""submit"" id=""submit1"" onClick=""document.myform.Action.value='CreateArticle'"" value=""生成选定"&Cl.Channel_Setting(2)&""">"
		Response.write "<input name=""Submit4"" type=""submit"" id=""Submit4"" onClick=""document.myform.Action.value='DelArticleHTML'"" value=""删除选定"&Cl.Channel_Setting(2)&"HTML"">"
		Response.write "&nbsp;&nbsp;&nbsp;&nbsp;<input name=""Submit3"" type=""submit"" id=""Submit3""  onClick=""document.myform.Action.value='CreateArticleAll'"" value=""生成所有"&Cl.Channel_Setting(2)&""">"
		Response.write "<input name=""Submit4"" type=""submit"" id=""Submit4"" onClick=""document.myform.Action.value='DelArticleHTMLAll'"" value=""删除所有"&Cl.Channel_Setting(2)&"HTML"">"
	Case Else
		Response.write "<input name=""submit"" type=""submit"" value=""删除选定"&Cl.Channel_Setting(2)&""" onClick=""document.myform.Action.Value='Del'"">"
		Response.write "&nbsp;&nbsp; <input type=""submit"" name=""Submit"" value=""批量移动到栏目..."" onClick=""document.myform.Action.value='MoveMore'"">"
		'Response.write "<select name=""TargetClassID"">"&ShowClass_Option(ChannelID,ClassID,2,1)&"</select>"
		Response.write "&nbsp;&nbsp; <input type=""submit"" name=""Submit"" value=""移动到专题："" onClick=""document.myform.Action.value='MoveToSpecial'"">"
		Response.write "<select name=""SpecialID"">"&ShowSpecial_Option(ChannelID,SpecialID,1)&"</select>"
	End Select
End Sub

Sub AddMain()
	Dim strCusTom
	Dim sKeyword,sAuthorName,sCopyFromName,sPrefixion
	Dim sKeywordV,sAuthorNameV,sCopyFromNameV
	strCusTom		= Split(Cl.Channel_Setting(21),"@@@")
	sKeyword		= Split(strCusTom(0),"$")
	sAuthorName		= Split(strCusTom(1),"$")
	sCopyFromName	= Split(strCusTom(2),"$")
	sPrefixion		= Split(strCusTom(3),"$")
	sKeywordV		= Split(Cl.GotTopic(strCusTom(0),60),"$")
	sAuthorNameV	= Split(Cl.GotTopic(strCusTom(1),60),"$")
	sCopyFromNameV	= Split(Cl.GotTopic(strCusTom(2),60),"$")
%>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title>添加文章</title>
<link rel="stylesheet" type="text/css" href="../Skins/User_Style.Css">
<script language = "JavaScript" src="../Inc/Js/Admin.js"></script>
<script language = "JavaScript">
function CheckForm()
{
  document.myform.Content.value=editor.Editor.document.body.innerHTML;
  if (document.myform.ClassID.value=="0")
  {
    alert("<%=Cl.Channel_Setting(2)%>所属栏目为外部栏目或您无此栏目添加权限！");
	document.myform.ClassID.focus();
	return false;
  }
  if (document.myform.Title.value=="")
  {
    alert("<%=Cl.Channel_Setting(2)%>标题不能为空！");
	document.myform.Title.focus();
	return false;
  }
  if (document.myform.Keyword.value=="")
  {
    alert("关键字不能为空！");
	document.myform.Keyword.focus();
	return false;
  }
  if (document.myform.IsLink.checked==true)
  {
	if (document.myform.LinkUrl.value=="")
	{
		alert("请输入连接地址！");
		document.myform.LinkUrl.focus();
		return false;
	 }
  }
  else
  {
	if (document.myform.Content.value=="")
	{
		alert("<%=Cl.Channel_Setting(2)%>内容不能为空！");
		editor.Editor.focus();
		return false;
	 }
  }
  for(var i=0;i<document.myform.TempUploadFiles.length;i++){
      if (document.myform.UploadFiles.value=="") document.myform.UploadFiles.value=document.myform.TempUploadFiles.options[i].value;
      else document.myform.UploadFiles.value+="@@@"+document.myform.TempUploadFiles.options[i].value;
  }
  return true;
}
</script>
</head>
<body leftmargin="0" topmargin="0" marginwidth="0" marginheight="0">
<form method="POST" name="myform" onSubmit="return CheckForm();" action="User_Article.asp" target="_self">
  <table border="0" align="center" cellpadding="0" cellspacing="1" class="border">
    <tr class="title">
      <td height="22" align="center" colspan=3><b>添加<%=Cl.Channel_Setting(2)%></b></td>
    </tr>
<!-- 
          <tr class="tdbg"> 
            <td width="100" align="right"><strong>所属栏目：</strong></td>
            <td colspan=2><Input type="hidden" name="ClassID" id="ClassID" value="0"><Input type="text" name="ClassIDv" id="ClassIDv" value="请选择栏目!" size=45 readonly Onclick="SelectClass('<%=ChannelID%>','ClassID')">&nbsp<Input type="button" Name="selectclassid" Onclick="SelectClass('<%=ChannelID%>','ClassID')" value="选择栏目">
			  &nbsp;&nbsp;&nbsp;&nbsp;<strong>专题：</strong>
			 <select name="SpecialID" id="SpecialID">
			<%'=ShowSpecial_Option(ChannelID,SpecialID,1)%>
			</select>
            </td>
          </tr>-->
          <tr class="tdbg"> 
            <td width="100" align="right"><strong>所属栏目：</strong></td>
            <td colspan=2><select name="ClassID">
			<option value="0" selected>请选择<%=Cl.Channel_Setting(2)%>栏目</option>
                <%=ShowClass_Option(ChannelID,ClassID,0,2)%>
              </select>&nbsp;&nbsp
			  <font color="#FF0000"><strong>注意：</strong></font><font color="#0000FF">不能指定为外部栏目</font>
            </td>
          </tr>
          <tr class="tdbg">
            <td width="100" align="right"><strong>所属专题：</strong></td>
            <td colspan="2">
			<select name="SpecialID" id="SpecialID" multiple style="height:90px;width:200px;">
			<%=ShowSpecial_Option(ChannelID,0,1)%>
			</select>&nbsp;&nbsp
			  <font color="#FF0000"><strong>说明：</strong></font><font color="#0000FF">按“Shift”“Ctrl”可多选</font>
			</td>
          </tr>
          <tr class="tdbg"> 
            <td width="100" align="right"><strong><%=Cl.Channel_Setting(2)%>标题：</strong></td>
            <td colspan="2">
              <table width="100%" border="0" cellpadding="0" cellspacing="1">
                <tr>
                  <td width="64">简短标题：</td>
                  <td>
                    <select name="Prefixion">
                      <option value="" selected>[前缀]</option>
					  <%for i=0 To Ubound(sPrefixion)%>
                      <option value="<%=sPrefixion(i)%>"><%=sPrefixion(i)%></option>
					  <%Next%>
                    </select>
					<input name="Title" type="text" id="Title" value="" size="40" maxlength="255"> <font color="#FF0000">*</font>&nbsp;<select name="TitleFontType" id="TitleFontType">
						<option value="0" selected>字形</option>
						<option value="0">规则</option>
						<option value="1">粗体</option>
						<option value="2">斜体</option>
						<option value="3">粗+斜</option>
					  </select>&nbsp;<input name="TitleFontColor" type="hidden" id="TitleFontColor" value="" size="10" onclick="Getcolor(ColorBG,'TitleFontColor');" Readonly> <img border=0 src="../images/Gcolor.gif" style="cursor:pointer;" onclick="Getcolor(this,'TitleFontColor');" title="选取标题颜色!" align="absmiddle" ID=ColorBG>&nbsp;<input name="Check" type="button" id="Check" value="检测标题" onClick="CheckTitle('Title','<%=ChannelID%>');">
					</td>
				</tr>
                <tr>
                  <td width="64">完整标题：</td>
                  <td><input name="TitleIntact" type="text" id="TitleIntact" value="" size="79" maxlength="255"></td>
				</tr>
				</table>
			</td>
          </tr>
          <tr class="tdbg"> 
            <td width="100" align="right"><strong>关 键 字：</strong></td>
            <td colspan="2"><input name="Keyword" type="text"
           id="Keyword" value="<%if ubound(sKeywordV)>-1 then response.write sKeywordV(0)%>" size="90" maxlength="255"> <font color="#FF0000">*</font><br>
			<font color="#808080">关 键 字：</font><font color="#0000FF"><%for i=0 to Ubound(sKeywordV)
			Response.write "<a href=""javascript:ToValue('add','Keyword','|"&sKeywordV(i)&"')"">"&sKeyword(i)&"</a>"
			if i<Ubound(sKeywordV) then Response.write "/"
			next%></font>&nbsp;&nbsp;<font color=#66666>more...</font><br>
              <font color="#0000FF">用来查找相关<%=Cl.Channel_Setting(2)%>，可输入多个关键字，中间用<font color="#FF0000">“|”</font>分开。不能出现&quot;&quot;'*?,.()等字符。</font></td>
          </tr>
          <tr class="tdbg"> 
            <td width="100" align="right"><strong>作&nbsp;&nbsp;&nbsp;&nbsp;者：</strong></td>
            <td colspan="2"> 姓名： 
              <input name="AuthorName" type="text"
           id="AuthorName" value="<%=Cl.User_Info(5)%>" size="20" maxlength="30"> 
              &nbsp;&nbsp;&nbsp;&nbsp;Email： 
              <input name="AuthorEmail" type="text" id="AuthorEmail" value="<%=Cl.User_Info(8)%>" size="40" maxlength="100"><br>
			<font color="#808080">作者选择：</font><font color="#0000FF"><%for i=0 to Ubound(sAuthorNameV)
			Response.write "<a href=""javascript:ToValue('','AuthorName','"&sAuthorNameV(i)&"')"">"&sAuthorName(i)&"</a>"
			if i<Ubound(sAuthorNameV) then Response.write "/"
			next%></font>&nbsp;&nbsp;<font color=#66666>more...</font></td>
          </tr>
          <tr class="tdbg"> 
            <td width="100" align="right"><strong>来&nbsp;&nbsp;&nbsp;&nbsp;源：</strong></td>
            <td colspan="2">名称： 
              <input name="CopyFromName" type="text"
           id="CopyFromName" value="<%=Cl.Web_Info(0)%>" size="20" maxlength="50"> 
              &nbsp;&nbsp;&nbsp;&nbsp;网&nbsp;址： 
              <input name="CopyFromUrl" type="text" id="CopyFromUrl" value="<%=Cl.Web_Info(4)%>" size="40" maxlength="200"><br>
			<font color="#808080">来源选择：</font><font color="#0000FF"><%for i=0 to Ubound(sCopyFromNameV)
			Response.write "<a href=""javascript:ToValue('','CopyFromName','"&sCopyFromNameV(i)&"')"">"&sCopyFromName(i)&"</a>"
			if i<Ubound(sCopyFromNameV) then Response.write "/"
			next%></font>&nbsp;&nbsp;<font color=#66666>more...</font></td>
          </tr>
          <tr class="tdbg">
            <td width="100" align="right"><strong><%=Cl.Channel_Setting(2)%>简介：</strong></td>
            <td colspan="2"><textarea name="ArticleIntro" ID="ArticleIntro" style="width:95%" rows="5"></textarea><br><a href="javascript:admin_Size(-5,'ArticleIntro')"><img src="images/minus.gif" unselectable="on" border='0'></a> <a href="javascript:admin_Size(5,'ArticleIntro')"><img src="images/plus.gif" unselectable="on" border='0'></a>&nbsp;&nbsp;</td>
          </tr>
           <tr class="tdbg">
            <td width="100" align="right"><strong>转向连接：</strong></td>
            <td colspan="2"><input name="IsLink" type="checkbox" id="IsLink" value="yes" OnClick="ChkLink();">&nbsp;转向连接</td>
          </tr>
          <tr class="tdbg" Id=ChkIsLink style="display:none;"> 
            <td width="100" align="right"><strong>连接地址：</strong></td>
            <td colspan="2"><input name="LinkUrl" type="text"
           id="LinkUrl" value="" size="82" maxlength="255"> <font color="#FF0000">*</font><br></td>
          </tr>
          <tr class="tdbg" Id=ChkNoLink>
            <td width="100" align="right"><strong><%=Cl.Channel_Setting(2)%>内容：</strong></td>
            <td colspan="2">
	<!------------------------------------->
          <table width="100%">
          <tr class="tdbg"> 
            <td colspan="2"><textarea name="Content" style="display:none"></textarea> 
              <IFRAME ID="editor" src="../Editor/Editor.asp?id=Content&style=aspoo&cid=<%=ChannelID%>&TObj=TempUploadFiles" frameborder="0" scrolling="no" width="95%" height="405"></IFRAME>
			  <br><font color="#006600">&middot;换行请按Shift+Enter，另起一段请按Enter</font>
            </td>
          </tr>
          <tr class="tdbg"> 
            <td width="70" align="right"><strong>分页方式：</strong></td>
            <td><select name="PaginationType" id="PaginationType">
                <option value="0" selected>不分页</option>
                <option value="1">自动分页</option>
                <option value="2">手动分页</option>
              </select> &nbsp;&nbsp;&nbsp;&nbsp;<strong><font color="#0000FF">注：</font></strong><font color="#0000FF">手动分页符标记为：</font><input name="NextPageLabel" type="button" id="NextPageLabel" value="[NextPage]" onClick="editor.Editor.focus();editor.insertHTML('[NextPage]');" style="cursor:hand;"><font color="#0000FF">点击插入，注意大小写。</font></td>
          </tr>
          <tr class="tdbg">
            <td align="right">&nbsp;</td>
            <td>自动分页时的每页大约字符数（包含HTML标记）：<strong> 
              <input name="MaxCharPerPage" type="text" id="MaxCharPerPage" value="10000" size="8" maxlength="8">
              </strong></td>
          </tr>
		  </table>
	<!------------------------------------->
		  </td>
          </tr>
          <tr class="tdbg"> 
            <td width="100" align="right"><strong>首页图片：</strong></td>
            <td colspan="2"><input name="DefaultPicUrl" type="text" id="DefaultPicUrl" size="80" maxlength="200" onclick="doPreview('DefaultPicUrl','<%=Cl.WebDir%>','<%=Cl.UploadDir%>')"><br><iframe style="top:2px" ID="UpFile" src="../User/Upload.asp?MID=1&ID=<%=ChannelID%>&Type=0&Obj=DefaultPicUrl&TObj=TempUploadFiles" frameborder=0 scrolling=no width="530" height="25"></iframe><br>
              用于在首页的图片<%=Cl.Channel_Setting(2)%>处显示，根目录用“{%webdir%}”，上传目录用“{%uploaddir%}” 
            </td>
          </tr>
          <tr class="tdbg"> 
            <td width="100" align="right"><strong>已 上 传：</strong></td>
            <td><select name="TempUploadFiles" style="width:500;height:132" size="2" onclick="doPreview('TempUploadFiles','<%=Cl.WebDir%>','<%=Cl.UploadDir%>')"></select><br>
				<input type="button" name="SetDefaultPic" value="设为首页图片" onclick="SetPicUrl('TempUploadFiles','DefaultPicUrl');">
				<input type="button" name="InsEditor" value="插入编辑器" onclick="InsertEditor('TempUploadFiles','<%=Cl.WebDir%>','<%=Cl.UploadDir%>');">
				<input type="hidden" name="UploadFiles" value="">
			</td>
            <td width=180>
				<fieldset style="height:100%">
				<legend>预览</legend>
				<table border=0 cellpadding=0 cellspacing=1 width="180" height="150" valign=top>
				<tr><td align=center valign=middle id=tdPreview height="100%">

				</td></tr>
				</table>
				</fieldset>
			</td>
          </tr>
		  <%if Cl.TrueChannelPurview_U(2,ChannelID) then%>
          <tr class="tdbg"> 
            <td width="100" align="right"><strong>阅读等级：</strong></td>
            <td colspan="2">
			<input name="ReadLevel" type="text" id="ReadLevel" value="5" size="82" onclick="SelectUserGroup('ReadLevel');" Readonly Disabled>&nbsp;<input type="checkbox" name="GetClassPurview" value="yes" checked onclick="document.myform.ReadLevel.disabled=this.checked">继承栏目权限<br><font color="#0000FF">只有具有相应权限的人才能阅读此<%=Cl.Channel_Setting(2)%>。</font></td>
          </tr>
          <tr class="tdbg"> 
            <td width="100" align="right"><strong>阅读<%=Cl.Web_Setting(28)%>：</strong></td>
            <td colspan="2"><input name="ReadPoint" type="text" id="ReadPoint" value="0" size="8" maxlength="5" style="text-align: right;"> <%=Cl.Web_Setting(29)%> &nbsp;&nbsp;&nbsp;&nbsp; <font color="#0000FF">如果大于0，则用户阅读此<%=Cl.Channel_Setting(2)%>时将消耗相应<%=Cl.Web_Setting(28)%>。（对游客无效）</font></td>
          </tr>
          <tr class="tdbg"> 
            <td width="100" align="right"><strong>阅读<%=Cl.Web_Setting(26)%>：</strong></td>
            <td colspan="2"><input name="ReadMoney" type="text" id="ReadMoney" value="0" size="8" maxlength="5" style="text-align: right;"> <%=Cl.Web_Setting(27)%> &nbsp;&nbsp;&nbsp;&nbsp; <font color="#0000FF">如果大于0，则用户阅读此<%=Cl.Channel_Setting(2)%>时将消耗相应<%=Cl.Web_Setting(26)%>。（对游客无效）</font></td>
          </tr>
          <tr class="tdbg">
            <td width="100" align="right"><strong>回扣设置：</strong></td>
            <td colspan="2">
			<%=Cl.Web_Setting(28)%>：<input name="BackPoint" type="text" id="BackPoint" value="0" size="5" maxlength="3" style="text-align: right;">&nbsp;<%=Cl.Web_Setting(29)%>＋<%=Cl.Web_Setting(28)%>的<input name="BackPointRate" type="text" id="BackPointRate" value="0" size="5" maxlength="2" style="text-align: right;">%<br>
			<%=Cl.Web_Setting(26)%>：<input name="BackMoney" type="text" id="BackMoney" value="0" size="5" maxlength="3" style="text-align: right;">&nbsp;<%=Cl.Web_Setting(27)%>＋<%=Cl.Web_Setting(26)%>的<input name="BackMoneyRate" type="text" id="BackMoneyRate" value="0" size="5" maxlength="2" style="text-align: right;">%<br><font color="#0000FF">即当用户游览或下载此内容时，给予一定的回扣给添加者！</font>
			</td>
		  </tr>
          <tr class="tdbg"> 
            <td width="100" align="right"><strong><%=Cl.Channel_Setting(2)%>性质：</strong></td>
            <td colspan="2"><input name="OnTop" type="checkbox" id="OnTop" value="yes">
              固顶<%=Cl.Channel_Setting(2)%>&nbsp;&nbsp;&nbsp;&nbsp; <input name="Hot" type="checkbox" id="Hot" value="yes" onclick="javascript:document.myform.Hits.value=<%=Clng(Cl.Web_Setting(14))%>">
              热点<%=Cl.Channel_Setting(2)%>&nbsp;&nbsp;&nbsp;&nbsp; <input name="Elite" type=checkbox id="Elite" value="yes">
              推荐<%=Cl.Channel_Setting(2)%>&nbsp;&nbsp;&nbsp;&nbsp;<%=Cl.Channel_Setting(2)%>评分等级： 
              <select name="Stars" id="Stars">
                <option value="5">★★★★★</option>
                <option value="4">★★★★</option>
                <option value="3" selected>★★★</option>
                <option value="2">★★</option>
                <option value="1">★</option>
                <option value="0">无</option>
              </select></td>
          </tr>
          <tr class="tdbg"> 
            <td width="100" align="right"><strong>点 击 数：</strong></td>
            <td colspan="2"><input name="Hits" type="text" id="Hits" value="0" size="10" maxlength="10"></td>
          </tr>
          <tr class="tdbg"> 
            <td width="100" align="right"><strong>录入时间：</strong></td>
            <td colspan="2"><input name="UpdateTime" type="text" id="UpdateTime" value="<%=now()%>" maxlength="50">
              时间格式为“年-月-日 时:分:秒”，如：<font color="#0000FF"><%=now()%></font></td>
          </tr>
          <tr class="tdbg">
            <td width="100" align="right"><strong>签收<%=Cl.Channel_Setting(2)%>：</strong></td>
            <td colspan="2"><input name="IsReceive" type="checkbox" id="IsReceive" value="yes" OnClick="ChkReceiver();">&nbsp;签收<%=Cl.Channel_Setting(2)%></td>
          </tr>
          <tr class="tdbg" ID="ShowReceiver" Style="display:none">
            <td width="100" align="right"><strong>签收用户：</strong></td>
            <td colspan="2" width="*">
               <table width="100%">
			    <tr>
                  <td width="100%"><textarea name="ReceiveUser" ID="ReceiveUser" style="width:95%" rows="5" readonly></textarea> 
                    <font color="#ff6600">*</font>
  			     </td>
                </tr> 
			    <tr> 
                  <td><input type="button" name="Select_User" id="Select_User" value="&nbsp;选择用户&nbsp;" onClick="window.open('User_SelectUsers.asp?Action=Receive', 'UserList', 'width=700,height=500,resizable=0,scrollbars=yes');">&nbsp;&nbsp;&nbsp;
				  自动签收：<Input type=text Name="AutoReceiveTime" ID="AutoReceiveTime" Value="0" size=5 maxlength="3"> 秒&nbsp;&nbsp;&nbsp;
				  文档类型：
					<select name="ReceiveType" id="ReceiveType">
					  <option value="0" selected>公众文档</option>
					  <OPTION value="1">专属文档</OPTION>
					</select>
  			     </td>
                </tr> 
			  </table>
			</td>
          </tr>
		<%end if%>
          <tr class="tdbg">
            <td width="100" align="right"><strong>立即发布：</strong></td>
            <td colspan="2"><input name="Passed" type="checkbox" id="Passed" value="yes" checked>
              是<font color="#0000FF">（如果选中的话将直接发布，否则审核后才能发布。）</font>&nbsp;&nbsp;<input name="NowCreate" type="checkbox" value="yes" checked>立即生成 </td>
          </tr>
  </table>
  <div align="center"> 
    <p> 
      <input name="Action" type="hidden" id="Action" value="SaveAdd">
      <input name="ChannelID" type="hidden" id="ChannelID" value="<%=ChannelID%>">
      <input name="Add" type="submit"  id="Add" value=" 添 加 " style="cursor:hand;">
      &nbsp; 
      <input name="Cancel" type="button" id="Cancel" value=" 取 消 " onClick="window.location.href='User_Article.Asp?ChannelID=<%=ChannelID%>'" style="cursor:hand;">
    </p>
  </div>
</form>
<script LANGUAGE='JavaScript'>
<!--
function ChkReceiver(){
if (document.getElementById('IsReceive').checked == true) {
	document.getElementById('ShowReceiver').style.display = '';
}else{
	document.getElementById('ShowReceiver').style.display = 'none';
}
}
function ChkLink(){
if (document.getElementById('IsLink').checked == true) {
	document.getElementById('ChkIsLink').style.display = '';
	document.getElementById('ChkNoLink').style.display = 'none';
}else{
	document.getElementById('ChkIsLink').style.display = 'none';
	document.getElementById('ChkNoLink').style.display = '';
}
}
//-->
</script>
<%
End Sub

Sub ModifyMain()
	dim rsInfo
	dim Author,AuthorName,AuthorEmail,CopyFrom,CopyFromName,CopyFromUrl
	dim strCusTom
	Dim sKeyword,sAuthorName,sCopyFromName,sPrefixion
	Dim sKeywordV,sAuthorNameV,sCopyFromNameV
	ArticleID		= Cl.ChkClng(request("ArticleID"))
	FoundErr=False
	Set rsInfo = Cl.Execute("select * From Cl_Article where ArticleID=" & ArticleID & "")
	if rsInfo.bof and rsInfo.eof then
		User_ShowErr("<li>找不到文章</li>")
	else
		ClassID	= rsInfo("ClassID")
		set tClass=Cl.Execute("select ClassName,RootID,ParentID,Depth,ParentPath From Cl_Class where ChannelID="&ChannelID&" and ClassID=" & ClassID)
		if tClass.bof and tClass.eof then
			tClass.Close :Set tClass=Nothing
			User_ShowErr("<li>找不到指定的栏目</li>")
		else
			ClassName	= tClass(0) : RootID	= tClass(1)
			ParentID	= tClass(2) : Depth		= tClass(3)
			ParentPath	= tClass(4)
			tClass.Close :Set tClass=Nothing
			if Not Cl.TrueChannelPurview_U(2,ChannelID) then
				dim sTempP,IsTruePurview
				sTempP=Split(ParentPath & "," & ClassID,",")
				IsTruePurview=False
				if rsInfo("Passed")=True then
					for i=1 to Ubound(sTempP)
						IsTruePurview = Cl.TrueClassPurview_U(1,ChannelID,sTempP(i))
						if IsTruePurview Then Exit For
					Next
				elseif rsInfo("Editor")=Cl.User_Info(5) then
					IsTruePurview=True
				else
					for i=1 to Ubound(sTempP)
						IsTruePurview = Cl.TrueClassPurview_U(2,ChannelID,sTempP(i))
						if IsTruePurview Then Exit For
					Next
				end if
				if Not IsTruePurview then
					User_ShowErr("<li>你无权修改此栏目下资料</li>")
				end if
			end if
		end if
	end if
	Author		= rsInfo("Author")
	CopyFrom	= rsInfo("CopyFrom")
	if instr(Author,"|")>0 then
		AuthorName = left(Author,instr(Author,"|")-1)
		AuthorEmail= right(Author,len(Author)-instr(Author,"|"))
	else
		AuthorName = Author
		AuthorEmail= ""
	end if
	if instr(CopyFrom,"|")>0 then
		CopyFromName= left(CopyFrom,instr(CopyFrom,"|")-1)
		CopyFromUrl	= right(CopyFrom,len(CopyFrom)-instr(CopyFrom,"|"))
	else
		CopyFromName= CopyFrom
		CopyFromUrl	= ""
	end if
	strCusTom		= Split(Cl.Channel_Setting(21),"@@@")
	sKeyword		= Split(strCusTom(0),"$")
	sAuthorName		= Split(strCusTom(1),"$")
	sCopyFromName	= Split(strCusTom(2),"$")
	sPrefixion		= Split(strCusTom(3),"$")
	sKeywordV		= Split(Cl.GotTopic(strCusTom(0),60),"$")
	sAuthorNameV	= Split(Cl.GotTopic(strCusTom(1),60),"$")
	sCopyFromNameV	= Split(Cl.GotTopic(strCusTom(2),60),"$")
%>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title>修改<%=Cl.Channel_Setting(2)%></title>
<link rel="stylesheet" type="text/css" href="../Skins/User_Style.Css">
<script language = "JavaScript" src="../Inc/Js/Admin.js"></script>
<script language = "JavaScript">
function CheckForm()
{
  document.myform.Content.value=editor.Editor.document.body.innerHTML;
  if (document.myform.ClassID.value=="0")
  {
    alert("<%=Cl.Channel_Setting(2)%>所属栏目为外部栏目或您无此栏目添加权限！");
	document.myform.ClassID.focus();
	return false;
  }
  if (document.myform.Title.value=="")
  {
    alert("<%=Cl.Channel_Setting(2)%>标题不能为空！");
	document.myform.Title.focus();
	return false;
  }
  if (document.myform.Keyword.value=="")
  {
    alert("关键字不能为空！");
	document.myform.Keyword.focus();
	return false;
  }
  if (document.myform.IsLink.checked==true)
  {
	if (document.myform.LinkUrl.value=="")
	{
		alert("请输入连接地址！");
		document.myform.LinkUrl.focus();
		return false;
	 }
  }
  else
  {
	if (document.myform.Content.value=="")
	{
		alert("<%=Cl.Channel_Setting(2)%>内容不能为空！");
		editor.Editor.focus();
		return false;
	 }
  }
  for(var i=0;i<document.myform.TempUploadFiles.length;i++){
      if (document.myform.UploadFiles.value=="") document.myform.UploadFiles.value=document.myform.TempUploadFiles.options[i].value;
      else document.myform.UploadFiles.value+="@@@"+document.myform.TempUploadFiles.options[i].value;
  }
  return true;
}
</script>
</head>
<body leftmargin="0" topmargin="0" marginwidth="0" marginheight="0">
<form method="POST" name="myform" onSubmit="return CheckForm();" action="User_Article.asp">
  <table border="0" align="center" cellpadding="0" cellspacing="1" class="border">
    <tr class="title">
      <td height="22" align="center" colspan=3><b>修改<%=Cl.Channel_Setting(2)%></b></td>
    </tr>
	<!--
          <tr class="tdbg"> 
            <td width="100" align="right"><strong>所属栏目：</strong></td>
            <td colspan=2><Input type="hidden" name="ClassID" id="ClassID" value="<%=ClassID%>"><Input type="text" name="ClassIDv" id="ClassIDv" value="<%=ClassID%>:<%=ClassName%>" size=45 readonly Onclick="SelectClass('<%=ChannelID%>','ClassID')">&nbsp<Input type="button" Name="selectclassid" Onclick="SelectClass('<%=ChannelID%>','ClassID')" value="选择栏目">
			  &nbsp;&nbsp;&nbsp;&nbsp;<strong>专题：</strong>
			  <select name="SpecialID" id="SpecialID">
			<%'=ShowSpecial_Option(ChannelID,SpecialID,1)%>
			</select>
            </td>
          </tr>-->
          <tr class="tdbg"> 
            <td width="100" align="right"><strong>所属栏目：</strong></td>
            <td colspan="2">
				<select name="ClassID">
				 <%=ShowClass_Option(ChannelID,rsInfo("ClassID"),0,2)%>
				</select>&nbsp;&nbsp;
				<font color="#FF0000"><strong>注意：</strong></font><font color="#0000FF">不能指定为外部栏目</font>
			</td>
          </tr>
          <tr class="tdbg">
            <td width="100" align="right"><strong>所属专题：</strong></td>
            <td colspan="2">
			<select name="SpecialID" id="SpecialID" multiple style="height:90px;width:200px;">
			<%=ShowSpecial_Option(ChannelID,rsInfo("SpecialID"),1)%>
			</select>&nbsp;&nbsp
			  <font color="#FF0000"><strong>说明：</strong></font><font color="#0000FF">按“Shift”“Ctrl”可多选</font>
			</td>
          </tr>
          <tr class="tdbg"> 
            <td width="100" align="right"><strong><%=Cl.Channel_Setting(2)%>标题：</strong></td>
            <td colspan="2">
              <table width="100%" border="0" cellpadding="0" cellspacing="1">
                <tr>
                  <td width="64">简短标题：</td>
                  <td>
                    <select name="Prefixion">
                      <option value="" selected>[前缀]</option>
					  <%for i=0 To Ubound(sPrefixion)%>
                      <option value="<%=sPrefixion(i)%>"><%=sPrefixion(i)%></option>
					  <%Next%>
                    </select>
					<input name="Title" type="text" id="Title" value="<%=rsInfo("Title")%>" size="50" maxlength="255"> <font color="#FF0000">*</font>&nbsp;<select name="TitleFontType" id="TitleFontType">
						<option value="0">字形</option>
						<option value="0">规则</option>
						<option value="1" <%if rsInfo("TitleFontType")=1 then response.write " selected"%>>粗体</option>
						<option value="2" <%if rsInfo("TitleFontType")=2 then response.write " selected"%>>斜体</option>
						<option value="3" <%if rsInfo("TitleFontType")=3 then response.write " selected"%>>粗+斜</option>
					  </select>&nbsp;<input name="TitleFontColor" type="hidden" id="TitleFontColor" value="<%=rsInfo("TitleFontColor")%>" size="10" onclick="Getcolor(ColorBG,'TitleFontColor');" Readonly> <img border=0 src="../images/Gcolor.gif" style="cursor:pointer;background-Color:<%=rsInfo("TitleFontColor")%>;" onclick="Getcolor(this,'TitleFontColor');" title="选取标题颜色!" align="absmiddle" ID=ColorBG>&nbsp;<input name="Check" type="button" id="Check" value="检测标题" onClick="CheckTitle('Title','<%=ChannelID%>');">
					</td>
				</tr>
                <tr>
                  <td width="64">完整标题：</td>
                  <td><input name="TitleIntact" type="text" id="TitleIntact" value="<%=rsInfo("TitleIntact")%>" size="79" maxlength="255"></td>
				</tr>
				</table>
			</td>
          </tr>
          <tr class="tdbg"> 
            <td width="100" align="right"><strong>关 键 字：</strong></td>
            <td colspan="2"><input name="Keyword" type="text"
           id="Keyword" value="<%=rsInfo("Keyword")%>" size="82" maxlength="255"> <font color="#FF0000">*</font><br>
			<font color="#808080">关 键 字：</font><font color="#0000FF"><%for i=0 to Ubound(sKeywordV)
			Response.write "<a href=""javascript:ToValue('add','Keyword','|"&sKeywordV(i)&"')"">"&sKeyword(i)&"</a>"
			if i<Ubound(sKeywordV) then Response.write "/"
			next%></font>&nbsp;&nbsp;<font color=#66666>more...</font><br>
              <font color="#0000FF">用来查找相关<%=Cl.Channel_Setting(2)%>，可输入多个关键字，中间用<font color="#FF0000">“|”</font>分开。不能出现&quot;'*?()等字符。</font></td>
          </tr>
          <tr class="tdbg"> 
            <td width="100" align="right"><strong>作&nbsp;&nbsp;&nbsp;&nbsp;者：</strong></td>
            <td colspan="2">姓名： 
              <input name="AuthorName" type="text"
           id="AuthorName" value="<%=AuthorName%>" size="20" maxlength="30"> 
              &nbsp;&nbsp;&nbsp;&nbsp;Email： 
              <input name="AuthorEmail" type="text" id="AuthorEmail" value="<%=AuthorEmail%>" size="40" maxlength="100"><br>
			<font color="#808080">作者选择：</font><font color="#0000FF"><%for i=0 to Ubound(sAuthorNameV)
			Response.write "<a href=""javascript:ToValue('','AuthorName','"&sAuthorNameV(i)&"')"">"&sAuthorName(i)&"</a>"
			if i<Ubound(sAuthorNameV) then Response.write "/"
			next%></font>&nbsp;&nbsp;<font color=#66666>more...</font>
            </td>
          </tr>
          <tr class="tdbg"> 
            <td width="100" align="right"><strong>来&nbsp;&nbsp;&nbsp;&nbsp;源：</strong></td>
            <td colspan="2">名称： 
              <input name="CopyFromName" type="text"
           id="CopyFromName" value="<%=CopyFromName%>" size="20" maxlength="50"> 
              &nbsp;&nbsp;&nbsp;&nbsp;网&nbsp;址： 
              <input name="CopyFromUrl" type="text" id="CopyFromUrl" value="<%=CopyFromUrl%>" size="40" maxlength="200"><br>
			<font color="#808080">来源选择：</font><font color="#0000FF"><%for i=0 to Ubound(sCopyFromNameV)
			Response.write "<a href=""javascript:ToValue('','CopyFromName','"&sCopyFromNameV(i)&"')"">"&sCopyFromName(i)&"</a>"
			if i<Ubound(sCopyFromNameV) then Response.write "/"
			next%></font>&nbsp;&nbsp;<font color=#66666>more...</font></td>
          </tr>
          <tr class="tdbg">
            <td width="100" align="right"><strong><%=Cl.Channel_Setting(2)%>简介：</strong></td>
            <td colspan="2"><textarea name="ArticleIntro" ID="ArticleIntro" style="width:95%" rows="5"><%=rsInfo("Intro")%></textarea><br><a href="javascript:admin_Size(-5,'ArticleIntro')"><img src="images/minus.gif" unselectable="on" border=0></a> <a href="javascript:admin_Size(5,'ArticleIntro')"><img src="images/plus.gif" unselectable="on" border='0'></a></td>
          </tr>
           <tr class="tdbg">
            <td width="100" align="right"><strong>转向连接：</strong></td>
            <td colspan="2"><input name="IsLink" type="checkbox" id="IsLink" value="yes" OnClick="ChkLink();" <%if rsInfo("IsLink")=True then%>Checked<%end if%>>&nbsp;转向连接</td>
          </tr>
           <tr class="tdbg" Id=ChkIsLink style="display:none;">
            <td width="100" align="right"><strong>连接地址：</strong></td>
            <td colspan="2"><input name="LinkUrl" type="text"
           id="LinkUrl" value="<%=rsInfo("HtmlFileUrl")%>" size="82" maxlength="255"> <font color="#FF0000">*</font><br></td>
          </tr>
          <tr class="tdbg" Id=ChkNoLink>
            <td width="100" align="right"><strong><%=Cl.Channel_Setting(2)%>内容：</strong></td>
            <td colspan="2">
               <table width="100%">
<!--==================================================-->
		  <tr class="tdbg"> 
            <td colspan="2"><textarea name="Content" style="display:none"><%=rsInfo("Content")%></textarea> 
              <IFRAME ID="editor" src="../Editor/Editor.asp?id=Content&style=aspoo&cid=<%=ChannelID%>&TObj=TempUploadFiles" frameborder="0" scrolling="no" width="95%" height="405"></IFRAME><br>
			  <font color="#006600">&middot;　换行请按Shift+Enter，另起一段请按Enter</font>
            </td>
          </tr>
          <tr class="tdbg"> 
            <td width="70" align="right"><strong>分页方式：</strong></td>
            <td><select name="PaginationType" id="PaginationType">
                <option value="0" <%if rsInfo("PaginationType")=0 then response.write " selected"%>>不分页</option>
                <option value="1" <%if rsInfo("PaginationType")=1 then response.write " selected"%>>自动分页</option>
                <option value="2" <%if rsInfo("PaginationType")=2 then response.write " selected"%>>手动分页</option>
              </select> &nbsp;&nbsp;&nbsp;&nbsp;<strong><font color="#0000FF">注：</font></strong><font color="#0000FF">手动分页符标记为：</font><input name="NextPageLabel" type="button" id="NextPageLabel" value="[NextPage]" onClick="editor.Editor.focus();editor.insertHTML('[NextPage]');" style="cursor:hand;"><font color="#0000FF">点击插入，注意大小写。</font></td>
          </tr>
          <tr class="tdbg">
            <td align="right">&nbsp;</td>
            <td>自动分页时的每页大约字符数（包含HTML标记）：<strong> 
              <input name="MaxCharPerPage" type="text" id="MaxCharPerPage" value="<%=rsInfo("MaxCharPerPage")%>" size="8" maxlength="8">
              </strong></td>
          </tr>
<!--==================================================-->
		  </table></td>
          </tr>
          <tr class="tdbg"> 
            <td width="100" align="right"><strong>首页图片：</strong></td>
            <td colspan="2"><input name="DefaultPicUrl" type="text" id="DefaultPicUrl" value="<%=rsInfo("DefaultPicUrl")%>" size="80" maxlength="200" onclick="doPreview('DefaultPicUrl','<%=Cl.WebDir%>','<%=Cl.UploadDir%>')">
              <br><iframe style="top:2px" ID="UpFile" src="../User/Upload.asp?ID=<%=ChannelID%>&Type=0&Obj=DefaultPicUrl&TObj=TempUploadFiles" frameborder=0 scrolling=no width="530" height="25"></iframe>
			  <br>用于在首页的图片<%=Cl.Channel_Setting(2)%>处显示，根目录用“{%webdir%}”，上传目录用“{%uploaddir%}”
            </td>
          </tr>
          <tr class="tdbg"> 
            <td width="100" align="right"><strong>已 上 传：</strong></td>
            <td><select name="TempUploadFiles" style="width:500;height:132" size="2" onclick="doPreview('TempUploadFiles','<%=Cl.WebDir%>','<%=Cl.UploadDir%>')"><%
				dim sUploadFiles
				sUploadFiles = Trim(rsInfo("UploadFiles"))
				if Instr(sUploadFiles,"@@@") >0 then
					sUploadFiles = Split(sUploadFiles,"@@@")
					for i=0 to Ubound(sUploadFiles)
				%>
					<option value="<%=sUploadFiles(i)%>"><%=sUploadFiles(i)%></option>
				<%
					Next
				elseif sUploadFiles<>"" then
				%>
				<option value="<%=sUploadFiles%>"><%=sUploadFiles%></option>
				<%end if%></select><br>
				<input type="button" name="SetDefaultPic" value="设为首页图片" onclick="SetPicUrl('TempUploadFiles','DefaultPicUrl');">
				<input type="button" name="InsEditor" value="插入编辑器" onclick="InsertEditor('TempUploadFiles','<%=Cl.WebDir%>','<%=Cl.UploadDir%>');">
				<input type="hidden" name="UploadFiles" value="">
			</td>
            <td width=180>
				<fieldset style="height:100%">
				<legend>预览</legend>
				<table border=0 cellpadding=0 cellspacing=1 width="180" height="150" valign=top>
				<tr><td align=center valign=middle id=tdPreview height="100%">

				</td></tr>
				</table>
				</fieldset>
			</td>
          </tr>
		   <%if Cl.TrueChannelPurview_U(3,ChannelID) then%>
          <tr class="tdbg"> 
            <td width="100" align="right"><strong>阅读等级：</strong></td>
            <td colspan="2"><input name="ReadLevel" type="text" id="ReadLevel" value="<%=rsInfo("ReadLevel")%>" size="82" onclick="SelectUserGroup('ReadLevel');" Readonly>&nbsp;<input type="checkbox" name="GetClassPurview" value="yes" onclick="document.myform.ReadLevel.disabled=this.checked">继承栏目权限<br><font color="#0000FF">只有具有相应权限的人才能阅读此<%=Cl.Channel_Setting(2)%>。</font></td>
          </tr>
          <tr class="tdbg">
            <td width="100" align="right"><strong>阅读<%=Cl.Web_Setting(28)%>：</strong></td>
            <td colspan="2"><input name="ReadPoint" type="text" id="ReadPoint" value="<%=rsInfo("ReadPoint")%>" size="8" maxlength="5" style="text-align: right;"> <%=Cl.Web_Setting(29)%> &nbsp;&nbsp;&nbsp;&nbsp; <font color="#0000FF">如果大于0，则用户阅读此<%=Cl.Channel_Setting(2)%>时将消耗相应<%=Cl.Web_Setting(28)%>。（对游客无效）</font></td>
          </tr>
          <tr class="tdbg">
            <td width="100" align="right"><strong>阅读<%=Cl.Web_Setting(26)%>：</strong></td>
            <td colspan="2"><input name="ReadMoney" type="text" id="ReadMoney" value="<%=rsInfo("ReadMoney")%>" size="8" maxlength="5" style="text-align: right;"> <%=Cl.Web_Setting(27)%> &nbsp;&nbsp;&nbsp;&nbsp; <font color="#0000FF">如果大于0，则用户阅读此<%=Cl.Channel_Setting(2)%>时将消耗相应<%=Cl.Web_Setting(26)%>。（对游客无效）</font></td>
          </tr>
          <tr class="tdbg">
            <td width="100" align="right"><strong>回扣设置：</strong></td>
            <td colspan="2">
			<%=Cl.Web_Setting(28)%>：<input name="BackPoint" type="text" id="BackPoint" value="<%=rsInfo("BackPoint")%>" size="5" maxlength="3" style="text-align: right;">&nbsp;<%=Cl.Web_Setting(29)%>＋<%=Cl.Web_Setting(28)%>的<input name="BackPointRate" type="text" id="BackPointRate" value="<%=rsInfo("BackPointRate")%>" size="5" maxlength="2" style="text-align: right;">%<br>
			<%=Cl.Web_Setting(26)%>：<input name="BackMoney" type="text" id="BackMoney" value="<%=rsInfo("BackMoney")%>" size="5" maxlength="3" style="text-align: right;">&nbsp;<%=Cl.Web_Setting(27)%>＋<%=Cl.Web_Setting(26)%>的<input name="BackMoneyRate" type="text" id="BackMoneyRate" value="<%=rsInfo("BackMoneyRate")%>" size="5" maxlength="2" style="text-align: right;">%<br><font color="#0000FF">即当用户游览或下载此内容时，给予一定的回扣给添加者！</font>
			</td>
		  </tr>
          <tr class="tdbg"> 
            <td width="100" align="right"><strong><%=Cl.Channel_Setting(2)%>性质：</strong></td>
            <td colspan="2"><input name="OnTop" type="checkbox" id="OnTop" value="yes" <% if rsInfo("OnTop")=True then response.Write "checked" end if%>>
              固顶<%=Cl.Channel_Setting(2)%>&nbsp;&nbsp;&nbsp;&nbsp; <input name="Hot" type="checkbox" id="Hot" value="yes" <% if rsInfo("Hot")=True then response.Write("checked") end if%>>
              热点<%=Cl.Channel_Setting(2)%>&nbsp;&nbsp;&nbsp;&nbsp; <input name="Elite" type=checkbox id="Elite" value="yes" <% if rsInfo("Elite")=True then response.Write("checked") end if%>>
              推荐<%=Cl.Channel_Setting(2)%>&nbsp;&nbsp;&nbsp;&nbsp;评分等级： 
              <select name="Stars" id="Stars">
                <option value="5" <%if rsInfo("Stars")=5 then response.write " selected"%>>★★★★★</option>
                <option value="4" <%if rsInfo("Stars")=4 then response.write " selected"%>>★★★★</option>
                <option value="3" <%if rsInfo("Stars")=3 then response.write " selected"%>>★★★</option>
                <option value="2" <%if rsInfo("Stars")=2 then response.write " selected"%>>★★</option>
                <option value="1" <%if rsInfo("Stars")=1 then response.write " selected"%>>★</option>
                <option value="0" <%if rsInfo("Stars")=0 then response.write " selected"%>>无</option>
              </select>
            </td>
          </tr>
          <tr class="tdbg"> 
            <td width="100" align="right"><strong>点 击 数：</strong></td>
            <td colspan="2"><input name="Hits" type="text" id="Hits" value="<%=rsInfo("Hits")%>" size="10" maxlength="10"> 
              &nbsp;&nbsp;<font color="#0000FF">这功能是提供给管理员作弊用的。不过尽量不要用呀！^_^</font></td>
          </tr>
          <tr class="tdbg"> 
            <td width="100" align="right"><strong>录入时间：</strong></td>
            <td colspan="2"><input name="UpdateTime" type="text" id="UpdateTime" value="<%=rsInfo("UpdateTime")%>" maxlength="50">  <font color=blue><--【<a href='javascript:ToValue("","UpdateTime","<%=now%>")'>设为当前时间</a>】</font>
			<br>时间格式为“年-月-日 时:分:秒”，如：<font color="#0000FF">2005-1-1 12:32:47</font> 
            </td>
          </tr>
          <tr class="tdbg">
            <td width="100" align="right"><strong>签收<%=Cl.Channel_Setting(2)%>：</strong></td>
            <td colspan="2"><input name="IsReceive" type="checkbox" id="IsReceive" value="yes" OnClick="ChkReceiver();" <%if rsInfo("Receive")=True then%>Checked<%end if%>>&nbsp;签收<%=Cl.Channel_Setting(2)%></td>
          </tr>
          <tr class="tdbg" ID="ShowReceiver" Style="display:none">
            <td width="100" align="right"><strong>签收用户：</strong></td>
            <td colspan="2" width="*">
               <table width="100%">
			    <tr>
                  <td width="100%"><textarea name="ReceiveUser" ID="ReceiveUser" style="width:95%" rows="5" readonly><%=rsInfo("ReceiveUser")%></textarea>
                    <font color="#ff6600">*</font>
  			     </td>
                </tr> 
			    <tr>
                  <td><input type="button" name="Select_User" id="Select_User" value="&nbsp;选择用户&nbsp;" onClick="window.open('User_SelectUsers.asp?Action=Receive', 'UserList', 'width=700,height=500,resizable=0,scrollbars=yes');">&nbsp;&nbsp;&nbsp;
				  自动签收：<Input type=text Name="AutoReceiveTime" ID="AutoReceiveTime" Value="<%=rsInfo("AutoReceiveTime")%>" size=5 maxlength="3"> 秒&nbsp;&nbsp;&nbsp;
				  文档类型：
					<select name="ReceiveType" id="ReceiveType">
					  <option value="0" <% if rsInfo("ReceiveType")=0 then%>selected<%end if%>>公众文档</option>
					  <OPTION value="1" <% if rsInfo("ReceiveType")=1 then%>selected<%end if%>>专属文档</OPTION>
					</select>
					<br>
					<font color=red>注意：签收<%=Cl.Channel_Setting(2)%>修改后，所有用户将要重新签收。</font>
  			     </td>
                </tr>
			  </table>
			</td>
          </tr>
          <tr class="tdbg"> 
            <td width="100" align="right"><strong>立即发布：</strong></td>
            <td colspan="2"><input name="Passed" type="checkbox" id="Passed" value="yes" <% if rsInfo("Passed")=True then response.Write("checked") end if%>>
              是<font color="#0000FF">（如果选中的话将直接发布，否则审核后才能发布。）</font>&nbsp;&nbsp;<input name="NowCreate" type="checkbox" value="yes" checked>立即生成</td>
          </tr>
          <tr class="tdbg"> 
            <td width="100" align="right"><font color=blue><strong>快捷操作：</strong></font></td>
            <td colspan="3"><%
'if Cl.TrueChannelPurview_U(2,ChannelID) then
	if rsInfo("Passed")=False then
		response.write "<a href='User_Property.asp?ChannelID="&ChannelID&"&Action=SetPassed&InfoID=" & rsInfo("ArticleID") & "'>通过审核</a>&nbsp;&nbsp;"
	Else
  		response.write "<a href='User_Property.asp?ChannelID="&ChannelID&"&Action=CancelPassed&InfoID=" & rsInfo("ArticleID") & "'>取消审核</a>&nbsp;&nbsp;"
  	end if
  	if rsInfo("OnTop")=False then
   		response.write "<a href='User_Property.asp?ChannelID="&ChannelID&"&Action=SetOnTop&InfoID=" & rsInfo("ArticleID") & "'>固顶</a>&nbsp;&nbsp;"
   	else
		response.write "<a href='User_Property.asp?ChannelID="&ChannelID&"&Action=CancelOnTop&InfoID=" & rsInfo("ArticleID") & "'>解固</a>&nbsp;&nbsp;" 
   	end if
  	if rsInfo("Elite")=False then
   		response.write "<a href='User_Property.asp?ChannelID="&ChannelID&"&Action=SetElite&InfoID=" & rsInfo("ArticleID") & "'>设为推荐</a>&nbsp;&nbsp;"
   	else
		response.write "<a href='User_Property.asp?ChannelID="&ChannelID&"&Action=CancelElite&InfoID=" & rsInfo("ArticleID") & "'>取消推荐</a>&nbsp;&nbsp;"
    end if
	if rsInfo("Deleted")=True then
		response.write "<a href='User_InfoDel.asp?ChannelID="&ChannelID&"&Action=Restore&InfoID="&rsInfo("ArticleID")&"'>还原</a>&nbsp;&nbsp;"
	else
		response.write "<a href='User_InfoDel.asp?Action=Del&InfoID=" & rsInfo("ArticleID") & "'>删除</a>&nbsp;&nbsp;" 
	end if
'end if
%>&nbsp;&nbsp;<a href="User_Comment.asp?ChannelID=<%=ChannelID%>&InfoID=<%=rsInfo("ArticleID")%>"> 管理此<%=Cl.Channel_Setting(2)%>的评论</a></td>
          </tr>
		  <%end if%>
  </table>
  <div align="center"> 
    <p> 
		<input name="Action" type="hidden" id="Action" value="SaveModify">
		<input name="ChannelID" type="hidden" id="ChannelID" value="<%=ChannelID%>">
		<input name="ArticleID" type="hidden" id="ArticleID" value="<%=rsInfo("ArticleID")%>">
		<input name="Save" type="submit"  id="Save" value="保存修改结果" style="cursor:hand;">
		&nbsp; 
		<input name="Add" type="submit" id="Add" value="添加为新<%=Cl.Channel_Setting(2)%>" onClick="document.myform.Action.value='SaveAdd';" style="cursor:hand;">
		&nbsp; 
		<input name="Cancel" type="button" id="Cancel" value=" 取 消 " onClick="window.location.href='User_Article.Asp?ChannelID=<%=ChannelID%>'" style="cursor:hand;">
    </p>
  </div>
</form>
<script LANGUAGE='JavaScript'>
<!--
CheckSel('Prefixion','<%=rsInfo("Prefixion")%>');
<%if rsInfo("Receive")=true then%>
document.getElementById('ShowReceiver').style.display = '';
<%end if
if rsInfo("IsLink")=true then%>
document.getElementById('ChkIsLink').style.display = '';
document.getElementById('ChkNoLink').style.display = 'none';
<%end if%>
function ChkReceiver(){
if (document.getElementById('IsReceive').checked == true) {
	document.getElementById('ShowReceiver').style.display = '';
}else{
	document.getElementById('ShowReceiver').style.display = 'none';
}
}
function ChkLink(){
if (document.getElementById('IsLink').checked == true) {
	document.getElementById('ChkIsLink').style.display = '';
	document.getElementById('ChkNoLink').style.display = 'none';
}else{
	document.getElementById('ChkIsLink').style.display = 'none';
	document.getElementById('ChkNoLink').style.display = '';
}
}
//-->
</script>
<%
rsInfo.close:set rsInfo=Nothing
End Sub

Sub DoSaveRecord()
	FoundErr		= false
	ArticleID		= Cl.ChkClng(Request.Form("ArticleID"))
	ClassID			= Cl.ChkClng(request.form("ClassID"))
	SpecialID		= Trim(request.Form("SpecialID"))
	Title			= Trim(request.form("Title"))
	Prefixion		= Trim(request.form("Prefixion"))
	TitleIntact		= Trim(request.form("TitleIntact"))
	TitleFontColor	= Trim(request.form("TitleFontColor"))
	TitleFontType	= Cl.ChkClng(request.form("TitleFontType"))
	Keyword			= Trim(request.form("Keyword"))
	Content			= Trim(request.form("Content"))
	Author			= Trim(request.form("Author"))
	AuthorName		= Trim(request.form("AuthorName"))
	AuthorEmail		= Trim(request.form("AuthorEmail"))
	CopyFrom		= Trim(request.form("CopyFrom"))
	CopyFromName	= Trim(request.form("CopyFromName"))
	CopyFromUrl		= Trim(request.form("CopyFromUrl"))
	UpdateTime		= Trim(request.form("UpdateTime"))
	DefaultPicUrl	= Trim(request.form("DefaultPicUrl"))
	Passed			= Trim(request.form("Passed"))
	NowCreate		= Trim(request.form("NowCreate"))
	OnTop			= Trim(request.form("OnTop"))
	Hot				= Trim(request.form("Hot"))
	Elite			= Trim(request.form("Elite"))
	Hits			= Cl.ChkClng(request.form("Hits"))
	PaginationType	= Cl.ChkClng(request.form("PaginationType"))
	MaxCharPerPage	= Cl.ChkClng(request.form("MaxCharPerPage"))
	ReadLevel		= Trim(request.form("ReadLevel"))
	ReadPoint		= Cl.ChkClng(request.form("ReadPoint"))
	ReadMoney		= Cl.ChkClng(request.form("ReadMoney"))
	BackPoint		= Cl.ChkClng(request.form("BackPoint"))
	BackPointRate	= Cl.ChkClng(request.form("BackPointRate"))
	BackMoney		= Cl.ChkClng(request.form("BackMoney"))
	BackMoneyRate	= Cl.ChkClng(request.form("BackMoneyRate"))
	Stars			= Cl.ChkClng(request.form("Stars"))
	IsReceive		= Trim(request.form("IsReceive"))
	ReceiveUser		= Trim(request.form("ReceiveUser"))
	AutoReceiveTime	= Trim(request.form("AutoReceiveTime"))
	ReceiveType		= Trim(request.form("ReceiveType"))
	ArticleIntro	= Trim(request.form("ArticleIntro"))
	IsLink			= Trim(request.form("IsLink"))
	LinkUrl			= Trim(request.form("LinkUrl"))
	UploadFiles		= Trim(request.form("UploadFiles"))
	Editor			= Cl.User_Info(5)
	if ClassID<=0 then
		founderr=true
		errmsg=errmsg & "<br><li>未指定文章所属栏目或者指定的栏目有下属子栏目</li>"
	end if
	if Title="" then
		founderr=true
		errmsg=ErrMsg & "<br><li>文章标题不能为空</li>"
	end if
	if KeyWord="" then
		founderr=true
		errmsg=errmsg & "<br><li>请输入文章关键字</li>"
	end if
	if IsLink="yes" then
		if LinkUrl="" then
			founderr=true
			errmsg=errmsg & "<br><li>连接地址不能为空</li>"
		end if
	else
		if Content="" then
			founderr=true
			errmsg=errmsg & "<br><li>文章内容不能为空</li>"
		end if
	end if
	if FoundErr=True then User_ShowErr(ErrMsg)
	set tClass=Cl.Execute("select ClassName,Depth,ParentPath,Child,BrowsePurview,DisabledAdd,AddPoint,AddIsChk,MaxLimit,IsOuter From Cl_Class where ClassID=" & ClassID)
	if tClass.bof and tClass.eof then
		FoundErr=True
		ErrMsg=ErrMsg & "<br><li>找不到指定的栏目</li>"
	else
		if tClass(9)=1 then
			FoundErr=True
			ErrMsg=ErrMsg & "<br><li>不能指定外部栏目</li>"
		elseif tClass(5)<>0 then
			FoundErr=True
			ErrMsg=ErrMsg & "<br><li>对不起，此栏目禁止添加资料</li>"
		else
			ClassName	= tClass(0) : Depth		= tClass(1)
			ParentPath	= tClass(2) : Child		= tClass(3)
			sAddPoint	= tClass(6) : sAddIsChk	= tClass(7)
			sMaxLimit	= tClass(8)
			if request("GetClassPurview")="yes" then ReadLevel="5"
		end if
	end if
	tClass.Close :Set tClass=Nothing
	'简介和标题过滤脏话
	if ArticleIntro="" then
		ArticleIntro="暂无简介"
	else
		ArticleIntro=Cl.ChkBadWords(ArticleIntro)
	end if
	Title		= Cl.ChkBadWords(Title)
	TitleIntact	= Cl.ChkBadWords(TitleIntact)
	if Content<>"" then
		if Cl.strLength(Content)>sMaxLimit and sMaxLimit<>0 then
			founderr=true
			errmsg=errmsg & "<br><li>文章内容大小超过了最大限制（"&sMaxLimit&" 字节！）</li>"
		end if
		dim strSiteUrl
		strSiteUrl=request.ServerVariables("HTTP_REFERER")
		strSiteUrl=lcase(left(strSiteUrl,instrrev(strSiteUrl,"$")))
		Content=replace(Content,strSiteUrl,"")
		if Cl.Web_Setting(4)="Yes" then  '开启脏话过滤
			Content=Cl.ChkBadWords(Content)
		end if
		if Trim(Cl.Web_Setting(9))="Yes" then
			Content=Cl.DeCode(Content,Trim(Cl.Web_Setting(10)))
		end if
	end if
	if PaginationType=1 and MaxCharPerPage=0 then
		FoundErr=True
		ErrMsg=ErrMsg & "<br><li>请指定自动分页时的每页大约字符数，必须大于0</li>"
	end if
'=====================================================================
	if IsReceive="yes" and SysTemVersion > 0 then
		if ReceiveUser="" then
			FoundErr=True
			ErrMsg=ErrMsg & "<br><li>请指定要签收的用户。</li>"
		else
			if Not Isnumeric(AutoReceiveTime) then AutoReceiveTime=0
			if Not Isnumeric(ReceiveType) then ReceiveType=0
			AutoReceiveTime=Clng(AutoReceiveTime)
			ReceiveType=Cint(ReceiveType)
			if ReceiveType<>0 And ReceiveType<>1 then ReceiveType=0
			if left(ReceiveUser,1)<>"|" then ReceiveUser="|"&ReceiveUser
			if right(ReceiveUser,1)<>"|" then ReceiveUser=ReceiveUser&"|"
		end if
	end if
 '=====================================================================
	if FoundErr=True then User_ShowErr(ErrMsg)
	if SpecialID="" then
		SpecialID="0"
	else
		SpecialID=Replace(SpecialID," ","")
		SpecialID=Replace(SpecialID,",,","")
		if Len(SpecialID)>250 then
			Dim TempStr,SpecialStr
			TempStr=Split(SpecialID,",")
			For i=0 to Ubound(TempStr)
				if TempStr(i)<>"" then SpecialStr=SpecialStr & "," & TempStr(i)
				if Len(SpecialStr)>=230 then Exit For
			Next
			SpecialID=SpecialStr
		End if
		SpecialID=Replace(","&SpecialID&",",",,",",")
	end if
	Keyword=Cl.ReplaceBadChar(Keyword)
	Keyword=Replace(Keyword,"||","|")
	if Left(Keyword,1)="|" then Keyword=Right(Keyword,Len(Keyword)-1)
	if Right(Keyword,1)="|" then Keyword=Left(Keyword,Len(Keyword)-1)
	'Title=Cl.HTMLEncode(Title)
	if Author<>"" then
		Author=Cl.HTMLEncode(Author)
	else
		if AuthorName="" and AuthorEmail="" then
			Author="佚名"
		else
			if AuthorName<>"" then
				Author=AuthorName
				if AuthorEmail<>"" then
			 		Author=Author & "|" & AuthorEmail
				end if
			end if
		end if
	end if
	if CopyFrom<>"" then
		CopyFrom=Cl.HTMLEncode(CopyFrom)
	else
		if CopyFromName="" and CopyFromUrl="" then
			CopyFrom="创力网"
		else
			if CopyFromName<>"" then
				CopyFrom=CopyFromName
				if CopyFromUrl<>"" then
					CopyFrom=CopyFrom & "|" & CopyFromUrl
				end if
			end if
		end if			
	end if
	if UpdateTime<>"" and IsDate(UpdateTime)=true then
		UpdateTime=CDate(UpdateTime)
	else
		UpdateTime=now()
	end if
	ReadLevel=Replace(ReadLevel," ","")
	if OnTop="yes" then
		OnTop=True
	else
		OnTop=False
	end if
	if Hot="yes" then
		Hot=True
	else
		Hot=False
	end if
	if Elite="yes" then
		Elite=True
	else
		Elite=False
	end if
	if Passed="yes" then
		Passed=True
	else
		Passed=False
	end if
	dim sTempP
	IsTruePurview	= False
	IsTruePurview_P	= False
	if Cl.TrueChannelPurview_U(2,ChannelID) then
		IsTruePurview	= True
		IsTruePurview_P	= True
	else
		sTempP=Split(ParentPath & "," & ClassID,",")
		for i=1 to Ubound(sTempP)
			IsTruePurview = Cl.TrueClassPurview_U(3,ChannelID,sTempP(i))
			if IsTruePurview Then Exit For
		Next
		for i=1 to Ubound(sTempP)
			IsTruePurview_P = Cl.TrueClassPurview_U(2,ChannelID,sTempP(i))
			if IsTruePurview_P Then Exit For
		Next
	end if
	if Not IsTruePurview then 
		User_ShowErr("<br><li>您无权在此栏目下添加或修改资料。</li>")
	end if
	set rs=server.createobject("adodb.recordset")
	if Action="SaveAdd" then
		Dim MaxAID
		MaxAID=Cl.Execute("select max(ArticleID) from Cl_Article")(0)
		if isnull(MaxAID) or Not IsNumeric(MaxAID) then MaxAID=0
		ArticleID=MaxAID+1
		sql="select * From Cl_Article"
		OpenConn : rs.open sql,Conn,1,3
		rs.addnew
		rs("ArticleID")=ArticleID
		rs("ChannelID")=ChannelID
		call SaveData()
		rs("Editor")=Editor
		rs.update
	ElseIf Action="SaveModify" then
  		if ArticleID<=0 then User_ShowErr("<br><li>不能确定ArticleID的值</li>")
		sql="select * From Cl_Article where ArticleID=" & ArticleID
		OpenConn : rs.open sql,Conn,1,3
		if rs.bof and rs.eof then
			rs.close : set rs=Nothing
			User_ShowErr("<br><li>找不到此资料，可能已经被其他人删除。</li>")
 		else
			Editor	= rs("Editor")
			if rs("Passed")=True then
				Cl.Execute_U("update " & Db.UserTable & " set " & Db.UserPoint & "=" & Db.UserPoint & "-"&sAddPoint&"," & Db.UserDataNum & "=" & Db.UserDataNum & "-1 where " & Db.UserName & "='" & Editor & "'")
			end if
			if rs("Receive")=True and SysTemVersion > 0 then
				DelReceiveUser rs("ReceiveUser"),ArticleID
			end if
			call SaveData()
			rs.update
		end if
	else
		User_ShowErr("<br><li>参数错误!</li>")
	end if
'=====================================================================
	if IsReceive="yes" and SysTemVersion > 0 then
		UpReceiveUser ReceiveUser,ArticleID
	end if
	rs.close : set rs=Nothing
	Cl.ChkUploadFile ArticleID,DefaultPicUrl & Content,UploadFiles
	Cl.SaveAdminLog
	SaveSuccess
End Sub

Sub SaveData()
	rs("ClassID")		= ClassID
	rs("SpecialID")		= SpecialID
	rs("Title")			= Title
	rs("Prefixion")		= Prefixion
	rs("TitleIntact")	= TitleIntact
	rs("TitleFontColor")= TitleFontColor
	rs("TitleFontType")	= TitleFontType
	rs("Content")		= Content
	rs("Keyword")		= Keyword
	rs("Hits")			= Hits
	rs("Author")		= Author
	rs("CopyFrom")		= CopyFrom
	if sAddIsChk=False then
		rs("Passed")	= True
		rs("Censor")	= Cl.User_Info(5)
		rs("CensorTime")= Date()
		Cl.Execute_U("update " & Db.UserTable & " set " & Db.UserPoint & "=" & Db.UserPoint & "+"&sAddPoint&"," & Db.UserDataNum & "=" & Db.UserDataNum & "+1 where " & Db.UserName & "='" & Editor & "'")
		Passed			= True
	elseif Passed and (IsTruePurview_P or Cint(Cl.User_Purview(ChannelID))=4) then
		rs("Passed")	= True
		rs("Censor")	= Cl.User_Info(5)
		rs("CensorTime")= Date()
		Cl.Execute_U("update " & Db.UserTable & " set " & Db.UserPoint & "=" & Db.UserPoint & "+"&sAddPoint&"," & Db.UserDataNum & "=" & Db.UserDataNum & "+1 where " & Db.UserName & "='" & Editor & "'")
	else
		rs("Passed")	= False
		Passed			= False
	end if
	rs("OnTop")			= OnTop
	rs("Hot")			= Hot
	rs("Elite")			= Elite
	rs("Stars")			= Stars
	rs("UpdateTime")	= UpdateTime
	rs("PaginationType")= PaginationType
	rs("MaxCharPerPage")= MaxCharPerPage
	rs("ReadLevel")		= ReadLevel
	rs("ReadPoint")		= ReadPoint
	rs("ReadMoney")		= ReadMoney
	rs("DefaultPicUrl")	= DefaultPicUrl
'=====================================================================
	if IsReceive="yes" and SysTemVersion > 0 then
		rs("Receive")	= True
		rs("ReceiveUser")=ReceiveUser
		rs("NotReceiveUser")=ReceiveUser
		rs("Received")	= ""
		rs("AutoReceiveTime")=AutoReceiveTime
		rs("ReceiveType")	= ReceiveType
	else
		rs("Receive")	= False
		rs("ReceiveUser")=""
		rs("NotReceiveUser")=""
		rs("Received")	= ""
	end if
'=====================================================================
	rs("Intro")=ArticleIntro
	if IsLink="yes" then
		rs("IsHtml")	= False
		rs("IsLink")	= True
		rs("HtmlFileUrl")=LinkUrl
	else
		rs("IsLink")	= False
		rs("HtmlFileUrl")=""
	end if
	rs("UploadFiles")	= UploadFiles
	rs("Nopass")		= False
	rs("BackPoint")		= BackPoint
	rs("BackPointRate")	= BackPointRate
	rs("BackMoney")		= BackMoney
	rs("BackMoneyRate")	= BackMoneyRate
end sub

Sub SaveSuccess()
%>
<html>
<head>
<title></title>
<link rel="stylesheet" type="text/css" href="../Skins/User_Style.Css">
</head>
<body leftmargin="0" topmargin="0" marginwidth="0" marginheight="0">
<br><br>
<table class="border" align=center width="400" border="0" cellpadding="0" cellspacing="1">
  <tr align=center> 
    <td  height="22" align="center" class="title"><b> 
      <%if action="SaveAdd" then%>添加<%else%>修改<%end if%><%=Cl.Channel_Setting(2)%>成功</b></td>
  </tr>
<%if Not Passed then%>
  <tr class="tdbg"> 
    <td height="60"><font color="#0000FF">注意：</font><br>
      &nbsp;&nbsp;&nbsp; 你的<%=Cl.Channel_Setting(2)%>尚未真正发表！只有等管理员审核并通过了你的<%=Cl.Channel_Setting(2)%>后，你所添加的<%=Cl.Channel_Setting(2)%>才会发表。</td>
  </tr>
<%end if%>
  <tr> 
    <td><table width="100%" border="0" cellpadding="2" cellspacing="1">
        <tr class="tdbg"> 
          <td width="100" align="right"><strong>所属栏目：</strong></td>
          <td><%=ShowManageClassPath(ChannelID,ClassName,ParentPath,Depth)%></td>
        </tr>
        <tr class="tdbg"> 
          <td width="100" align="right"><strong><%=Cl.Channel_Setting(2)%>标题：</strong></td>
          <td><%= Title %></td>
        </tr>
        <tr class="tdbg"> 
          <td width="100" align="right"><strong>作&nbsp;&nbsp;&nbsp;&nbsp;者：</strong></td>
          <td><%= Author %></td>
        </tr>
        <tr class="tdbg"> 
          <td width="100" align="right"><strong>来&nbsp;&nbsp;&nbsp;&nbsp;源：</strong></td>
          <td><%= CopyFrom %></td>
        </tr>
        <tr class="tdbg"> 
          <td width="100" align="right"><strong>关 键 字：</strong></td>
          <td><%=KeyWord%></td>
        </tr>
      </table></td>
  </tr>
  <tr class="tdbg"> 
    <td height="30" align="center">【<a href="User_Article.Asp?Action=Modify&ChannelID=<%=ChannelID%>&ArticleID=<%=ArticleID%>">修改<%=Cl.Channel_Setting(2)%></a>】&nbsp;【<a href="User_Article.Asp?Action=Add&ChannelID=<%=ChannelID%>">继续添加<%=Cl.Channel_Setting(2)%></a>】&nbsp;【<a href="User_Article.Asp?ChannelID=<%=ChannelID%>"><%=Cl.Channel_Setting(2)%>管理</a>】</td>
  </tr>
</table>
<%
if Clng(Cl.Channel_Setting(10))=1 and Passed and NowCreate="yes" and IsLink<>"yes" then
	Dim sCreate
	'if CBool(Cl.Channel_Setting(14)) and CBool(Cl.Channel_Setting(15)) then

	'	sCreate="CreateArticle,CreateClass,CreateUpDate,CreateElite,CreateIndex,CreateWebIndex"
	'	if SpecialID>0 then sCreate=sCreate&",CreateSpecial"
	'else
		sCreate="CreateArticle,CreateIndex,CreateWebIndex"
	'end if
	%>
	<br><br>
	<iframe width="100%" height="220" frameborder="0" src="User_Create_Article.asp?ChannelID=<%=ChannelID%>&Action=<%=sCreate%>&InfoID=<%=ArticleID%>&ClassID=<%=ClassID%>&SpecialID=<%=SpecialID%>" name="Make"></iframe>
<%
end if
End Sub

Sub ShowInfoMain()
	ArticleID=Cl.ChkClng(request("ArticleID"))
	sql="select * From Cl_Article where ArticleID=" & ArticleID & ""
	Set rs= Server.CreateObject("ADODB.Recordset")
	OpenConn : rs.open sql,Conn,1,1
	if rs.bof and rs.eof then
		rs.close : Set rs=Nothing
		User_ShowErr("<br><li>找不到文章</li>")
	else
		ChannelID=rs("ChannelID"):ClassID=rs("ClassID")
		set tClass=Cl.Execute("select ClassName,RootID,ParentID,Depth,ParentPath From Cl_Class where ChannelID="&ChannelID&" and ClassID=" & ClassID)
		if tClass.bof and tClass.eof then
			set tClass=Nothing
			User_ShowErr("<br><li>找不到指定的栏目</li>")
		else
			ClassName=tClass(0):RootID=tClass(1)
			ParentID=tClass(2):Depth=tClass(3)
			ParentPath=tClass(4)
		end if
		set tClass=Nothing
	end if
	Set ClUbb=New Cls_UbbCode
%>
<html>
<head>
<title><%=rs("Title")%></title>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<link href="../Skins/User_Style.Css" rel="stylesheet" type="text/css">
<script Language=Javascript src="../Inc/Js/Font.Js"></script>
<script language=javascript>
function ConfirmDel()
{
   if(confirm("确定要删除选中的文章吗？本操作将把选中的文章移到回收站中。必要时您可从回收站中恢复！"))
     return true;
   else
     return false;
}
</script>
</head>
<body leftmargin="0" topmargin="0" marginwidth="0" marginheight="0">
<table width="100%" border="0" align="center" cellpadding="2" cellspacing="1" class="border">
  <tr class="title"> 
    <td height="22">
	您的位置：&nbsp;<a href="User_Article.Asp?ChannelID=<%=ChannelID%>"><%=Cl.Channel_Setting(2)%>管理</a>&nbsp;&gt;&gt;&nbsp;<%
if ParentID>0 then
	dim sqlPath,rsPath
	sqlPath="select ClassID,ClassName From Cl_Class where ChannelID="&ChannelID&" and ClassID in (" & ParentPath & ") order by Depth"
	set rsPath=server.createobject("adodb.recordset")
	rsPath.open sqlPath,Conn,1,1
	do while not rsPath.eof
		response.Write "<a href='User_Article.Asp?ChannelID="&ChannelID&"&ClassID=" & rsPath(0) & "'>" & rsPath(1) & "</a>&nbsp;&gt;&gt;&nbsp;"
		rsPath.movenext
	loop
	rsPath.close:set rsPath=Nothing
end if
response.write "<a href='User_Article.Asp?ChannelID="&ChannelID&"&ClassID=" & ClassID & "'>" & ClassName & "</a>&nbsp;&gt;&gt;&nbsp;"
response.write rs("Title")
%>	
	</td>
    <td width="100" height="22" align="right">
<%
if rs("OnTop")=true then
	response.Write("<font color=blue>顶</font>&nbsp;")
else
	response.write("&nbsp;&nbsp;&nbsp;")
end if
if rs("Hot")=True then
	response.write("<font color=red>热</font>&nbsp;")
else
	response.write("&nbsp;&nbsp;&nbsp;")
end if
if rs("Elite")=true then
	response.write("<font color=green>荐</font>")
else
	response.write("&nbsp;&nbsp;")
end if
%>
    </td>
  </tr>
  <tr align="center" class="tdbg"> 
    <td height="40" colspan="2" valign="bottom"><font size="5"><%=rs("Title")%></font></td>
  </tr>
  <tr align="center" class="tdbg">
    <td colspan="2">
        <%
		dim Author,CopyFrom
		Author=rs("Author"):CopyFrom=rs("CopyFrom")
		response.write "作者："
		if instr(Author,"|")>0 then
			response.write "<a href='mailto:" & right(Author,len(Author)-instr(Author,"|")) & "'>" & left(Author,instr(Author,"|")-1) & "</a>"
		else
			response.write Author
		end if
		response.write "&nbsp;&nbsp;&nbsp;&nbsp;来源："
		if instr(CopyFrom,"|")>0 then
			response.write "<a href='" & right(CopyFrom,len(CopyFrom)-instr(CopyFrom,"|")) & "'>" & left(CopyFrom,instr(CopyFrom,"|")-1) & "</a>"
		else
			response.write CopyFrom
		end if
		response.write "&nbsp;&nbsp;&nbsp;&nbsp;点击数：" & rs("Hits") & "&nbsp;&nbsp;&nbsp;&nbsp;文章录入：<a href='User_Article.Asp?ChannelID="&ChannelID&"&Field=Editor&Keyword=" & rs("Editor") & "'>" & rs("Editor") & "</a>"
		%>
    </td>
  </tr>
  <%if rs("Receive")=True and SysTemVersion > 0 then%>
  <tr class="tdbg">
    <td colspan="2" align="center"><table border="0" cellpadding="0" cellspacing="1" align="center" style="BORDER-RIGHT: #009ace 1px solid; BORDER-TOP: #009ace 1px solid; BORDER-LEFT: #009ace 1px solid; WIDTH: 500; BORDER-BOTTOM: #009ace 1px solid; BACKGROUND-COLOR: #ffffff;TABLE-LAYOUT: fixed;">
        <tr>
          <td class="title" align="center">签 收 文 章 属 性</td>
        </tr>
        <tr class="tdbg">
          <td align="left" style="LEFT: 20px; WIDTH: 100%; WORD-WRAP: break-word"><b>文档属性：</b><%
			if rs("ReceiveType")=1 then
				Response.write "<font color=""#0000ff"">专属文档</font>"
			else
				Response.write "公众文档"
			end if
			%></td>
        </tr>
        <tr class="tdbg">
          <td align="left" style="LEFT: 20px; WIDTH: 100%; WORD-WRAP: break-word"><b>要签收用户：</b><%=replace(DelHeadTail(Rs("ReceiveUser")),"|",",")%></td>
        </tr>
        <tr class="tdbg">
          <td align="left" style="LEFT: 20px; WIDTH: 100%; WORD-WRAP: break-word"><b>已签收用户：</b><%=replace(DelHeadTail(Rs("Received")),"|",",")%></td>
        </tr>
		<% 
		Dim sNotReceiveUser
		sNotReceiveUser=Trim(replace(DelHeadTail(Rs("NotReceiveUser")),"|",","))
		if sNotReceiveUser<>"" then
		%>
        <tr class="tdbg" style="LEFT: 20px; WIDTH: 100%; WORD-WRAP: break-word">
          <td align="left"><b>未签收用户：</b><%=sNotReceiveUser%></td>
        </tr>
		<%end if%>
        <tr class="tdbg">
          <td align="left" style="LEFT: 20px; WIDTH: 100%; WORD-WRAP: break-word"><b>自动签收时间：</b><%=rs("AutoReceiveTime")%> 秒</td>
        </tr>
      </table>
    </td>
  </tr>
  <%end if%>
  <tr class="tdbg">
    <td colspan="2"><table width="100%" height="100%" border="0" cellpadding="0" cellspacing="5">
        <tr>
          <td height="200" valign="top"><p><%=ClUbb.UbbCode(rs("Content"))%></p></td>
        </tr>
      </table>
    </td>
  </tr>
  <tr class="tdbg"><td colspan="2">
      <li>上一篇文章： 
        <%
	  dim rsPrev
	  sql="Select Top 1 ArticleID,Title From Cl_Article Where Deleted=False and ArticleID<" & rs("ArticleID") & " order by ArticleID desc"
	  Set rsPrev= Server.CreateObject("ADODB.Recordset")
	  rsPrev.open sql,Conn,1,1
	  if rsPrev.Eof then
	  	response.write "没有了"
	  else
	  	response.write "<a href='User_Article.Asp?Action=Show&ChannelID="&ChannelID&"&ArticleID="&rsPrev("ArticleID")& "'>"&rsPrev("Title") & "</a>"
	  end if
	  rsPrev.close
	  set rsPrev=Nothing
	  %>
      </li>
      <br> <li> 下一篇文章： 
        <%
	  dim rsNext
	  sql="Select Top 1 ArticleID,Title From Cl_Article Where Deleted=False and ArticleID>" & rs("ArticleID") & " order by ArticleID asc"
	  Set rsNext= Server.CreateObject("ADODB.Recordset")
	  rsNext.open sql,Conn,1,1
	  if rsNext.Eof then
	  	response.write "没有了"
	  else
	  	response.write "<a href='User_Article.Asp?Action=Show&ChannelID="&ChannelID&"&ArticleID="&rsNext("ArticleID")& "'>"&rsNext("Title") & "</a>"
	  end if
	  rsNext.close
	  set rsNext=Nothing
	  %>
      </li></td>
  </tr>
  <tr align="right" class="tdbg"> 
    <td height="21" colspan="2">
<%
response.write "<strong>可用操作：</strong>"
if Cl.TrueChannelPurview_U(2,ChannelID) then
	if rs("Deleted")=True then
		if Cl.TrueChannelPurview_U(1,ChannelID) then response.write "<a href='User_InfoDel.asp?ChannelID="&ChannelID&"&Action=Restore&InfoID="&rs("ArticleID")&"'>还原</a>&nbsp;&nbsp;"
	else
		response.write "<a href='User_Article.Asp?Action=Modify&ChannelID="&ChannelID&"&ArticleID=" & rs("ArticleID") & "'>修改</a>&nbsp;&nbsp;<a href='User_InfoDel.asp?ChannelID="&ChannelID&"&Action=Del&InfoID=" & rs("ArticleID") & "' onclick='return ConfirmDel();'>删除</a>&nbsp;&nbsp;" 
	end if
end if
if Cl.TrueChannelPurview_U(1,ChannelID) then
	response.write "<a href='User_InfoMove.asp?ChannelID="&ChannelID&"&InfoID=" & rs("ArticleID") & "'>移动</a>&nbsp;&nbsp;"
end if
if Cl.TrueChannelPurview_U(2,ChannelID) then
	if rs("Passed")=false then
		response.write "<a href='User_Property.asp?ChannelID="&ChannelID&"&Action=SetPassed&InfoID=" & rs("ArticleID") & "'>通过审核</a>&nbsp;&nbsp;"
	Else
  		response.write "<a href='User_Property.asp?ChannelID="&ChannelID&"&Action=CancelPassed&InfoID=" & rs("ArticleID") & "'>取消审核</a>&nbsp;&nbsp;"
  	end if
end if
if Cl.TrueChannelPurview_U(1,ChannelID) then
  	if rs("OnTop")=false then
   		response.write "<a href='User_Property.asp?ChannelID="&ChannelID&"&Action=SetOnTop&InfoID=" & rs("ArticleID") & "'>固顶</a>&nbsp;&nbsp;"
   	else
		response.write "<a href='User_Property.asp?ChannelID="&ChannelID&"&Action=CancelOnTop&InfoID=" & rs("ArticleID") & "'>解固</a>&nbsp;&nbsp;" 
   	end if
  	if rs("Elite")=false then
   		response.write "<a href='User_Property.asp?ChannelID="&ChannelID&"&Action=SetElite&InfoID=" & rs("ArticleID") & "'>设为推荐</a>"
   	else
		response.write "<a href='User_Property.asp?ChannelID="&ChannelID&"&Action=CancelElite&InfoID=" & rs("ArticleID") & "'>取消推荐</a>"
    end if
end if
%></td>
  </tr>
</table>
<%
rs.close:set rs=Nothing
%>
<br>
<table width="100%" border="0" align="center" cellpadding="0" cellspacing="0"><tr>
    <td>
      <strong>相关评论：</strong><br>
<%
dim rsComment
sql="select * from Cl_Comment where ChannelID="&ChannelID&" and InfoID=" & ArticleID
Set rsComment= Server.CreateObject("ADODB.Recordset")
rsComment.open sql,Conn,1,1
if rsComment.eof then
	response.write "&nbsp;&nbsp;&nbsp;&nbsp;暂时没有任何人对本文章发表评论"
else
%>
      <table width="100%" border="0" cellspacing="1" cellpadding="2" class="border" style="word-break:break-all">
        <tr align="center" class="title"> 
          <td width="30" height="22"><strong>ID</strong></td>
          <td height="22"><strong>内容</strong></td>
          <td width="60" height="22"><strong>评论人</strong></td>
          <td width="120" height="22"><strong>评论人IP</strong></td>
          <td width="120" height="22"><strong>评论时间</strong></td>
          <td width="100" height="22"><strong>操作</strong></td>
        </tr>
<%
	do while not rsComment.eof
%>
        <tr class="tdbg"> 
          <td width="30" align="center"><%= rsComment("CommentID") %></td>
          <td><% response.write "<a href=# title='" & rsComment("Content") & "'>" & left(rsComment("Content"),25) & "</a>" %></td>
          <td width="60" align="center"><%= rsComment("UserName") %></td>
          <td width="120" align="center"><%=rsComment("IP")%></td>
          <td width="120" align="center"><%= rsComment("WriteTime") %></td>
          <td width="100" align="center">
		  <%
		  if Clng(Cl.User_Purview(0))=1 or Clng(Cl.User_Purview(1))<=2 then
			  if rsComment("ReplyName")<>"" then
				  response.write "&nbsp;&nbsp;&nbsp;&nbsp;"
			  else
				  response.write "<a href='User_Comment.asp?ChannelID="&ChannelID&"&Action=Reply&CommentID=" & rsComment("Commentid") & "'>回复</a>&nbsp;&nbsp;"
			  end if
			  response.write "<a href='User_Comment.asp?ChannelID="&ChannelID&"&Action=Modify&CommentID=" & rsComment("Commentid") & "'>修改</a>&nbsp;&nbsp;"
			  response.write "<a href='User_Comment.asp?ChannelID="&ChannelID&"&Action=Del&CommentID=" & rsComment("CommentID") & "'>删除</a>"
		  end if%>
		  </td>
        </tr>
        <%if rsComment("ReplyName")<>"" then%>
		<tr class="tdbg" onMouseOut="this.className='tdbg'" onMouseOver="this.className='tdbg2'"> 
          <td align="center">&nbsp;</td>
          <td colspan="4"><%response.write "管理员【" & rsComment("ReplyName") & "】于 " & rsComment("ReplyTime") & " 回复：<br><div style='padding:0px 20px'>" & ClUbb.UbbCode(rsComment("ReplyContent")) & "</div>"%></td>
          <td align="center"><a href="User_Comment.asp?ChannelID=<%=ChannelID%>Action=Reply&CommentID=<%=rsComment("CommentID")%>">修改回复内容</a></td>
		</tr>
        <%
		end if
		rsComment.movenext
	loop
%>
      </table>
<%
end if
rsComment.close:set rsComment=Nothing
%>
	</td>
  </tr>
</table>
<%
Set ClUbb=Nothing
End Sub
%>
<%
'<!--
'┌───────────────────────────────────────────────────────┐
'│														 │
'│		CreateLive CMS Version 3.1						 │
'│　　　　　　　　				Powered by Aspoo.CN	 	 │
'│　		　　　　　　　　　　						 │
'│　	邮箱: aspoo@126.com			Info@aspoo.cn　　	 │
'│		ＱＱ: 3315263				596197794			 │
'│		网站: www.aspoo.cn			www.aspoo.com		 │
'│		论坛: bbs.aspoo.cn			bbs.aspoo.com		 │
'│														 │
'│	Copyright (C) 2005 Aspoo.CN All Rights Reserved.	 │
'└───────────────────────────────────────────────────────┘
'-->
%>
