<%
	Class F
		Public Function ACT_DateStr(DateForm)
			 IF DateForm = 0 Then
		 		Response.Write"<option value=""0"" Selected>-不显示日期-</option>"
			 Else
		 		Response.Write "<option value=""0"">-不显示日期-</option> "
			 End IF
			  If CStr(DateForm) = "1" Then Str = " Selected" Else Str = ""
			   ACT_DateStr = ACT_DateStr & ("<option value=""1""" & Str & " >2005-10-1</option>")
			  If CStr(DateForm) = "2" Then Str = " Selected" Else Str = ""
			   ACT_DateStr = ACT_DateStr & ("<option value=""2""" & Str & ">2005.10.1</option>")
			  If CStr(DateForm) = "3" Then Str = " Selected" Else Str = ""
			   ACT_DateStr = ACT_DateStr & ("<option value=""3""" & Str & ">2005/10/1</option>")
			  If CStr(DateForm) = "4" Then Str = " Selected" Else Str = ""
			   ACT_DateStr = ACT_DateStr & ("<option value=""4""" & Str & ">10/1/2005</option>")
			  If CStr(DateForm) = "5" Then Str = " Selected" Else Str = ""
			   ACT_DateStr = ACT_DateStr & ("<option value=""5""" & Str & ">2005年10月</option>")
			  If CStr(DateForm) = "6" Then Str = " Selected" Else Str = ""
			   ACT_DateStr = ACT_DateStr & ("<option value=""6""" & Str & ">2005年10月1日</option>")
			  If CStr(DateForm) = "7" Then Str = " Selected" Else Str = ""
			   ACT_DateStr = ACT_DateStr & ("<option value=""7""" & Str & ">10.1.2005</option>")
			  If CStr(DateForm) = "8" Then Str = " Selected" Else Str = ""
			   ACT_DateStr = ACT_DateStr & ("<option value=""8""" & Str & ">10-1-2005</option>")
			  If CStr(DateForm) = "9" Then Str = " Selected" Else Str = ""
			   ACT_DateStr = ACT_DateStr & ("<option value=""9""" & Str & ">10/1</option>")
			  If CStr(DateForm) = "10" Then Str = " Selected" Else Str = ""
			   ACT_DateStr = ACT_DateStr & ("<option value=""10""" & Str & ">10.1</option>")
			  If CStr(DateForm) = "11" Then Str = " Selected" Else Str = ""
			   ACT_DateStr = ACT_DateStr & ("<option value=""11""" & Str & ">10月1日</option>")
			  If CStr(DateForm) = "12" Then Str = " Selected" Else Str = ""
			   ACT_DateStr = ACT_DateStr & ("<option value=""12""" & Str & ">1日12时</option>")
			  If CStr(DateForm) = "13" Then Str = " Selected" Else Str = ""
			   ACT_DateStr = ACT_DateStr & ("<option value=""13""" & Str & ">1日12点</option>")
			  If CStr(DateForm) = "14" Then Str = " Selected" Else Str = ""
			   ACT_DateStr = ACT_DateStr & ("<option value=""14""" & Str & ">12时12分</option>")
			  If CStr(DateForm) = "15" Then Str = " Selected" Else Str = ""
			   ACT_DateStr = ACT_DateStr & ("<option value=""15""" & Str & ">12:12</option>")
			  If CStr(DateForm) = "16" Then Str = " Selected" Else Str = ""
			   ACT_DateStr = ACT_DateStr & ("<option value=""16""" & Str & ">10-1</option>")
			   If CStr(DateForm) = "17" Then Str = " Selected" Else Str = ""
			   ACT_DateStr = ACT_DateStr & ("<option value=""17""" & Str & ">10/1 12:00</option>")
			  
			  ACT_DateStr = ACT_DateStr & ("<optgroup  label=""-----加括号格式-----""></optgroup>")

			  If CStr(DateForm) = "21" Then Str = " Selected" Else Str = ""
			   ACT_DateStr = ACT_DateStr & ("<option value=""21""" & Str & " >(2005-10-1)</option>") 
			  If CStr(DateForm) = "22" Then Str = " Selected" Else Str = ""
			   ACT_DateStr = ACT_DateStr & ("<option value=""22""" & Str & ">(2005.10.1)</option>")
			  If CStr(DateForm) = "23" Then Str = " Selected" Else Str = ""
			   ACT_DateStr = ACT_DateStr & ("<option value=""23""" & Str & ">(2005/10/1)</option>")
			  If CStr(DateForm) = "24" Then Str = " Selected" Else Str = ""
			   ACT_DateStr = ACT_DateStr & ("<option value=""24""" & Str & ">(10/1/2005)</option>")
			  If CStr(DateForm) = "25" Then Str = " Selected" Else Str = ""
			   ACT_DateStr = ACT_DateStr & ("<option value=""225""" & Str & ">(2005年10月)</option>")
			  If CStr(DateForm) = "26" Then Str = " Selected" Else Str = ""
			   ACT_DateStr = ACT_DateStr & ("<option value=""26""" & Str & ">(2005年10月1日)</option>")
			  If CStr(DateForm) = "27" Then Str = " Selected" Else Str = ""
			   ACT_DateStr = ACT_DateStr & ("<option value=""27""" & Str & ">(10.1.2005)</option>")
			  If CStr(DateForm) = "28" Then Str = " Selected" Else Str = ""
			   ACT_DateStr = ACT_DateStr & ("<option value=""28""" & Str & ">(10-1-2005)</option>")
			  If CStr(DateForm) = "29" Then Str = " Selected" Else Str = ""
			   ACT_DateStr = ACT_DateStr & ("<option value=""29""" & Str & ">(10/1)</option>")
			  If CStr(DateForm) = "30" Then Str = " Selected" Else Str = ""
			   ACT_DateStr = ACT_DateStr & ("<option value=""30""" & Str & ">(10.1)</option>")
			  If CStr(DateForm) = "31" Then Str = " Selected" Else Str = ""
			   ACT_DateStr = ACT_DateStr & ("<option value=""31""" & Str & ">(10月1日)</option>")
			  If CStr(DateForm) = "32" Then Str = " Selected" Else Str = ""
			   ACT_DateStr = ACT_DateStr & ("<option value=""32""" & Str & ">(1日12时)</option>")
			  If CStr(DateForm) = "33" Then Str = " Selected" Else Str = ""
			   ACT_DateStr = ACT_DateStr & ("<option value=""33""" & Str & ">(1日12点)</option>")
			  If CStr(DateForm) = "34" Then Str = " Selected" Else Str = ""
			   ACT_DateStr = ACT_DateStr & ("<option value=""34""" & Str & ">(12时12分)</option>")
			  If CStr(DateForm) = "35" Then Str = " Selected" Else Str = ""
			   ACT_DateStr = ACT_DateStr & ("<option value=""35""" & Str & ">(12:12)</option>")
			  If CStr(DateForm) = "36" Then Str = " Selected" Else Str = ""
			   ACT_DateStr = ACT_DateStr & ("<option value=""36""" & Str & ">(10-1)</option>")
			  If CStr(DateForm) = "37" Then Str = " Selected" Else Str = ""
			   ACT_DateStr = ACT_DateStr & ("<option value=""37""" & Str & ">(10/1 12:00)</option>")


			  ACT_DateStr = ACT_DateStr & ("<optgroup  label=""-----加中括号格式-----""></optgroup>")
			  If CStr(DateForm) = "41" Then Str = " Selected" Else Str = ""
			   ACT_DateStr = ACT_DateStr & ("<option value=""41""" & Str & ">[2005-10-1]</option>")
			  If CStr(DateForm) = "42" Then Str = " Selected" Else Str = ""
			   ACT_DateStr = ACT_DateStr & ("<option value=""42""" & Str & ">[2005.10.1]</option>")
			  If CStr(DateForm) = "43" Then Str = " Selected" Else Str = ""
			   ACT_DateStr = ACT_DateStr & ("<option value=""43""" & Str & ">[2005/10/1]</option>")
			  If CStr(DateForm) = "44" Then Str = " Selected" Else Str = ""
			   ACT_DateStr = ACT_DateStr & ("<option value=""44""" & Str & ">[10/1/2005]</option>")
			  If CStr(DateForm) = "45" Then Str = " Selected" Else Str = ""
			   ACT_DateStr = ACT_DateStr & ("<option value=""45""" & Str & ">[2005年10月]</option>")
			  If CStr(DateForm) = "46" Then Str = " Selected" Else Str = ""
			   ACT_DateStr = ACT_DateStr & ("<option value=""46""" & Str & ">[2005年10月1日]</option>")
			  If CStr(DateForm) = "47" Then Str = " Selected" Else Str = ""
			   ACT_DateStr = ACT_DateStr & ("<option value=""47""" & Str & ">[10.1.2005]</option>")
			  If CStr(DateForm) = "48" Then Str = " Selected" Else Str = ""
			   ACT_DateStr = ACT_DateStr & ("<option value=""48""" & Str & ">[10-1-2005]</option>")
			  If CStr(DateForm) = "49" Then Str = " Selected" Else Str = ""
			   ACT_DateStr = ACT_DateStr & ("<option value=""49""" & Str & ">[10/1]</option>")
			  If CStr(DateForm) = "50" Then Str = " Selected" Else Str = ""
			   ACT_DateStr = ACT_DateStr & ("<option value=""50""" & Str & ">[10.1]</option>")
			  If CStr(DateForm) = "51" Then Str = " Selected" Else Str = ""
			   ACT_DateStr = ACT_DateStr & ("<option value=""51""" & Str & ">[10月1日]</option>")
			  If CStr(DateForm) = "52" Then Str = " Selected" Else Str = ""
			   ACT_DateStr = ACT_DateStr & ("<option value=""52""" & Str & ">[1日12时]</option>")
			  If CStr(DateForm) = "53" Then Str = " Selected" Else Str = ""
			   ACT_DateStr = ACT_DateStr & ("<option value=""53""" & Str & ">[1日12点]</option>")
			  If CStr(DateForm) = "54" Then Str = " Selected" Else Str = ""
			   ACT_DateStr = ACT_DateStr & ("<option value=""54""" & Str & ">[12时12分]</option>")
			  If CStr(DateForm) = "55" Then Str = " Selected" Else Str = ""
			   ACT_DateStr = ACT_DateStr & ("<option value=""55""" & Str & ">[12:12]</option>")
			  If CStr(DateForm) = "56" Then Str = " Selected" Else Str = ""
			   ACT_DateStr = ACT_DateStr & ("<option value=""56""" & Str & ">[10-1]</option>")
			  If CStr(DateForm) = "57" Then Str = " Selected" Else Str = ""
			   ACT_DateStr = ACT_DateStr & ("<option value=""57""" & Str & ">[10/1 12:00]</option>")
		End Function
	


		Public Function ACT_ArticleSort(ArticleSort)
			If ArticleSort = "ID Desc" Then
			ACT_ArticleSort=ACT_ArticleSort&("<option value='ID Desc' selected>文章ID(降序)</option>")
			Else
			ACT_ArticleSort=ACT_ArticleSort&("<option value='ID Desc'>文章ID(降序)</option>")
			End If
			If ArticleSort = "ID Asc" Then
			ACT_ArticleSort=ACT_ArticleSort&("<option value='ID Asc' selected>文章ID(升序)</option>")
			Else
			ACT_ArticleSort=ACT_ArticleSort&("<option value='ID Asc'>文章ID(升序)</option>")
			End If
			If ArticleSort = "UpdateTime Asc" Then
			ACT_ArticleSort=ACT_ArticleSort&("<option value='UpdateTime Asc' selected>更新时间(升序)</option>")
			Else
			ACT_ArticleSort=ACT_ArticleSort&("<option value='UpdateTime Asc'>更新时间(升序)</option>")
			End If
			If ArticleSort = "UpdateTime Desc" Then
			 ACT_ArticleSort=ACT_ArticleSort&("<option value='UpdateTime Desc' selected>更新时间(降序)</option>")
			Else
			 ACT_ArticleSort=ACT_ArticleSort&("<option value='UpdateTime Desc'>更新时间(降序)</option>")
			End If
			If ArticleSort = "Hits Asc" Then
			 ACT_ArticleSort=ACT_ArticleSort&("<option value='Hits Asc' selected>点击数(升序)</option>")
			Else
			 ACT_ArticleSort=ACT_ArticleSort&("<option value='Hits Asc'>点击数(升序)</option>")
			End If
			If ArticleSort = "Hits Desc" Then
			  ACT_ArticleSort=ACT_ArticleSort&("<option value='Hits Desc' selected>点击数(降序)</option>")
			Else
			  ACT_ArticleSort=ACT_ArticleSort&("<option value='Hits Desc'>点击数(降序)</option>")
			End If 

			If ArticleSort = "Digg Desc" Then
			  ACT_ArticleSort=ACT_ArticleSort&("<option value='Digg Desc' selected>digg支持(降序)</option>")
			Else
			  ACT_ArticleSort=ACT_ArticleSort&("<option value='Digg Desc'>digg支持(降序)</option>")
			End If 

			If ArticleSort = "down Desc" Then
			  ACT_ArticleSort=ACT_ArticleSort&("<option value='down Desc' selected>down反对(降序)</option>")
			Else
			  ACT_ArticleSort=ACT_ArticleSort&("<option value='down Desc'>down反对(降序)</option>")
			End If 
		End Function
		Public Function ActCMS_DIY_F(ModeID,W,DIY_Article)
		Dim ActCMS__SQL1,ActCMS__SQL2
		Set ActCMS__SQL1 = server.CreateObject("adodb.recordset")
			ActCMS__SQL2= "Select ACT_DiY from Mode_Act where ModeID="& ModeID
			ActCMS__SQL1.Open ActCMS__SQL2,Conn,1,3
			If W=1  Then 
				If Trim(ActCMS__SQL1("ACT_DiY"))<>"" Then
					ActCMS_DIY_F=ActCMS__SQL1("ACT_DiY"):Exit Function 
				Else 
					ActCMS_DIY_F="1":Exit Function 
				End If 
			End If 
			ActCMS__SQL1("ACT_DiY")=DIY_Article
			ActCMS__SQL1.update
		End Function


	Public Function GroupOption(Selected)
	 Dim RSObj,GroupName:Set RSObj=Server.CreateObject("Adodb.Recordset")
	    RSObj.Open "Select GroupID,GroupSetting From Group_ACT",Conn,1,1
	  	Do While Not RSObj.Eof
		   GroupName=Split(RSObj(1),"^@$@^")(0)
		   IF Selected=RSObj(0) Then
			GroupOption=GroupOption & "<option value=""" & RSObj(0) & """ Selected>" &GroupName & "</option>"
		   Else
			GroupOption=GroupOption & "<option value=""" & RSObj(0) & """>" & GroupName & "</option>"
		   End If
		RSObj.MoveNext
		Loop
	  RSObj.Close:Set RSObj=Nothing
	End Function	



	Public Function ACT_LabelFolder(Selected)
	 Dim RSObj
	    Set RSObj = ACTCMS.ACTExe("Select ID,Foldername From ACT_LabelFolder")
	  	Do While Not RSObj.Eof
		   IF Selected=RSObj(0) Then
			ACT_LabelFolder=ACT_LabelFolder & "<option value=""" & RSObj(0) & """ Selected>" & RSObj(1) & "</option>"& vbCrLf
		   Else
			ACT_LabelFolder=ACT_LabelFolder & "<option value=""" & RSObj(0) & """>" & RSObj(1) & "</option>"& vbCrLf
		   End If
		RSObj.MoveNext
		Loop
	  RSObj.Close:Set RSObj=Nothing
	End Function	

End Class 
	Dim AF
	Set AF = New F
%>