<!--#include file="../inc/AspCms_SettingClass.asp" -->
<%
'=====================================================================
'安全校验码
dim vercode

vercode=""   '此处取值请自行修改，必须与发布规则的检查网址中vercode参数一致

if vercode<>trim(request("vercode")) then
	response.Write("[err]vercode错误[/err]")
	response.End()
end if

'=====================================================================

sub echomsg(str)
	response.Write("[err]"&str&"[/err]")
	response.End()
End sub

dim ContentID, LanguageID, SortID, GroupID, Exclusive, Title, Title2, TitleColor, IsOutLink, OutLink, Author, ContentSource, ContentTag, Content, ContentStatus, IsTop, IsRecommend, IsImageNews, IsHeadline, IsFeatured, ContentOrder, IsGenerated, Visits, AddTime, ImagePath, IndexImage, DownURL, PageTitle, PageKeywords, PageDesc, PageFileName, spec, EditTime,DownGroupID,IsNoComment,Star,Timeing,TimeStatus,VideoGroupID,CHvalue,SpecCategory
'SpecCategory用于判断是哪个类型的自定义参数
dim sortType, keyword, page, psize, order, ordsc, sortTypeName
sortType=getForm("sortType","post")
sortid=getForm("sortid","post")	
keyword=getForm("title","post")
if isnul(keyword) then echomsg "缺少标题"
	
if (not isNul(sortType)) and (not isnum(sortType)) then sortType="2"
	
select case sortType
	case "2"
		sortTypeName ="文章"
		SpecCategory = "C"
	case "3"
		sortTypeName ="产品"
		SpecCategory = "P"
	case "4"
		sortTypeName ="下载"
		SpecCategory = "DL"
	case "5"
		sortTypeName ="招聘"
		SpecCategory = "HR"
	case "6"
		sortTypeName ="相册"
		SpecCategory = "FO"

	case "8"
		sortTypeName = "视频"
		SpecCategory = "VI"
		
end select 
'单篇1,文章2,产品3,下载4,招聘5,相册6,链接7，视频8
	
Sub searchContent
	dim i,orderStr,whereStr,sqlStr,rsObj,allPage,allRecordset,numPerPage
	if isNul(page) then page=1 else page=clng(page)
	whereStr=" where Title = '"&keyword&"'"
	
	if not isNul(sortid) and sortid<>"0" then  whereStr=whereStr&" and a.SortID in("&getSubSort(sortID, 1)&")"
	if not isNul(sortType) then whereStr = whereStr&" and b.SortType="&sortType

	sqlStr = "select ContentID from {prefix}Content as a, {prefix}Sort as b"&whereStr&" and a.SortID=b.SortID and ContentStatus<>2 "


	set rsObj = conn.Exec(sqlStr,"r1")
	allRecordset = rsObj.recordcount 
	if allRecordset=0 then
		response.Write("[no]")
	else  
		response.Write("[yes]")
	end if
	rsObj.close : set rsObj = nothing	
End Sub

searchContent
%>