⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 index.asp

📁 一个功能强大的asp招聘求职系统
💻 ASP
📖 第 1 页 / 共 3 页
字号:
		Cmd.CommandText="dv_list"
		Cmd.CommandType=4
		Cmd.Parameters.Append cmd.CreateParameter("@boardid",3)
		Cmd.Parameters.Append cmd.CreateParameter("@pagenow",3)
		Cmd.Parameters.Append cmd.CreateParameter("@pagesize",3)
		Cmd.Parameters.Append cmd.CreateParameter("@tl",3)
		Cmd.Parameters.Append cmd.CreateParameter("@topicmode",3)
		Cmd.Parameters.Append cmd.CreateParameter("@totalrec",3,2)
		Cmd("@boardid")=Dvbbs.BoardID
		Cmd("@pagenow")=page
		Cmd("@pagesize")=Cint(Dvbbs.Board_Setting(26))
		Cmd("@topicmode")=TopicMode
		Cmd("@tl")=0
		Set Rs=Cmd.Execute
		If Not Rs.EoF Then
			SQL=Rs.GetRows(-1)
			Set topidlist=Dvbbs.ArrayToxml(sql,rs,"row","topic")
		Else
			Set topidlist=Nothing
		End If
	Else
		Set Rs = Server.CreateObject ("adodb.recordset")
		If Cint(TopicMode)=0 Then
			Sql="Select  TopicID,boardid,title,postusername,postuserid,dateandtime,child,hits,votetotal,lastpost,lastposttime,istop,isvote,isbest,locktopic,Expression,TopicMode,Mode,GetMoney,GetMoneyType,UseTools,IsSmsTopic,hidename From Dv_Topic Where BoardID="&Dvbbs.BoardID&" And IsTop=0 Order By LastPostTime Desc"
		Else
			Sql="Select  TopicID,boardid,title,postusername,postuserid,dateandtime,child,hits,votetotal,lastpost,lastposttime,istop,isvote,isbest,locktopic,Expression,TopicMode,Mode,GetMoney,GetMoneyType,UseTools,IsSmsTopic,hidename From Dv_Topic Where Mode="&TopicMode&" and BoardID="&Dvbbs.BoardID&" And IsTop=0  Order By LastPostTime Desc"
		End If
		Rs.Open Sql,Conn,1,1
		If Page >1 Then
			Rs.Move (page-1) * Clng(Dvbbs.Board_Setting(26))
		End If
		If Not Rs.EoF Then
			SQL=Rs.GetRows(Dvbbs.Board_Setting(26))
			Set topidlist=Dvbbs.ArrayToxml(sql,rs,"row","topic")
		Else
			Set topidlist=Nothing
		End If
	End If
	SQL=Empty
	If Not topidlist Is Nothing Then 
		For Each Node in topidlist.documentElement.SelectNodes("row")
				Node.selectSingleNode("@title").text=Dvbbs.ChkBadWords(Node.selectSingleNode("@title").text)
				If Not Node.selectSingleNode("@topicmode").text ="1"  Then
						Node.selectSingleNode("@title").text=replace(Node.selectSingleNode("@title").text,"<","&lt;")
				End If
				Node.selectSingleNode("@postusername").text=Dvbbs.ChkBadWords(Node.selectSingleNode("@postusername").text)
				i=0
				For each lastpost in split(Node.selectSingleNode("@lastpost").text,"$")
					Node.attributes.setNamedItem(topidlist.createNode(2,"lastpost_"& i,"")).text=lastpost
					i=i+1
				Next
				If Dvbbs.Board_Setting(60)<>"" And Dvbbs.Board_Setting(60)<>"0" Then
					If Dvbbs.Board_Setting(38) = "0" Then
							PostTime = Node.selectSingleNode("@lastpost_2").text
					Else
							PostTime = Node.selectSingleNode("@dateandtime").text
					End If
					If DateDiff("n",Posttime,Now)+Cint(Dvbbs.Forum_Setting(0)) < CLng(Dvbbs.Board_Setting(61)) Then
						Node.attributes.setNamedItem(topidlist.createNode(2,"datedifftime","")).text=DateDiff("n",Posttime,Now)+Cint(Dvbbs.Forum_Setting(0))
					End If
				End If
			Next
		XMLDom.documentElement.appendChild(topidlist.documentElement)
	End If
		Set Rs=Nothing
	Dvbbs.SqlQueryNum = Dvbbs.SqlQueryNum + 1
End Sub
Sub transform_topicList()
	If (Not Response.IsClientConnected) and Dvbbs.userid=0 Then
		Response.Clear
		Session(Dvbbs.CacheName & "UserID")=empty
		Response.End
	End If
	Dim proc,XMLStyle,node,cnode
	If Not IsObject(Application(Dvbbs.CacheName & "_listtemplate_"& Dvbbs.SkinID)) Then
		Set Application(Dvbbs.CacheName & "_listtemplate_"& Dvbbs.SkinID)=Server.CreateObject("Msxml2.XSLTemplate" & MsxmlVersion )
		Set XMLStyle=Server.CreateObject("Msxml2.FreeThreadedDOMDocument"& MsxmlVersion )
		XMLStyle.loadxml template.html(1) ' 
		'XMLStyle.load Server.MapPath("index_list.xslt")
		'插入各种图片的设置数据
		Set Node=XMLStyle.createNode(1,"xsl:variable","http://www.w3.org/1999/XSL/Transform")
		Set CNode=XMLStyle.createNode(2,"name","")
		CNode.text="picurl"
		Node.attributes.setNamedItem(CNode)
		node.text=Dvbbs.Forum_PicUrl
		XMLStyle.documentElement.appendChild(node)
		Set Node=XMLStyle.createNode(1,"xsl:variable","http://www.w3.org/1999/XSL/Transform")
		Set CNode=XMLStyle.createNode(2,"name","")
		CNode.text="pic_nofollow"
		Node.attributes.setNamedItem(CNode)
		node.text=Dvbbs.mainpic(10)
		XMLStyle.documentElement.appendChild(node)
		Set Node=XMLStyle.createNode(1,"xsl:variable","http://www.w3.org/1999/XSL/Transform")
		Set CNode=XMLStyle.createNode(2,"name","")
		CNode.text="pic_follow"
		Node.attributes.setNamedItem(CNode)
		node.text=Dvbbs.mainpic(11)
		XMLStyle.documentElement.appendChild(node)
		Set Node=XMLStyle.createNode(1,"xsl:variable","http://www.w3.org/1999/XSL/Transform")
		Set CNode=XMLStyle.createNode(2,"name","")
		CNode.text="ztopic"
		Node.attributes.setNamedItem(CNode)
		node.text=Dvbbs.mainpic(0)
		XMLStyle.documentElement.appendChild(node)
		Set Node=XMLStyle.createNode(1,"xsl:variable","http://www.w3.org/1999/XSL/Transform")
		Set CNode=XMLStyle.createNode(2,"name","")
		CNode.text="istopic"
		Node.attributes.setNamedItem(CNode)
		node.text=Dvbbs.mainpic(1)
		XMLStyle.documentElement.appendChild(node)
		Set Node=XMLStyle.createNode(1,"xsl:variable","http://www.w3.org/1999/XSL/Transform")
		Set CNode=XMLStyle.createNode(2,"name","")
		CNode.text="opentopic"
		Node.attributes.setNamedItem(CNode)
		node.text=Dvbbs.mainpic(2)
		XMLStyle.documentElement.appendChild(node)
		Set Node=XMLStyle.createNode(1,"xsl:variable","http://www.w3.org/1999/XSL/Transform")
		Set CNode=XMLStyle.createNode(2,"name","")
		CNode.text="hottopic"
		Node.attributes.setNamedItem(CNode)
		node.text=Dvbbs.mainpic(3)
		XMLStyle.documentElement.appendChild(node)
		Set Node=XMLStyle.createNode(1,"xsl:variable","http://www.w3.org/1999/XSL/Transform")
		Set CNode=XMLStyle.createNode(2,"name","")
		CNode.text="ilocktopic"
		Node.attributes.setNamedItem(CNode)
		node.text=Dvbbs.mainpic(4)
		XMLStyle.documentElement.appendChild(node)
		Set Node=XMLStyle.createNode(1,"xsl:variable","http://www.w3.org/1999/XSL/Transform")
		Set CNode=XMLStyle.createNode(2,"name","")
		CNode.text="besttopic"
		Node.attributes.setNamedItem(CNode)
		node.text=Dvbbs.mainpic(5)
		XMLStyle.documentElement.appendChild(node)
		Set Node=XMLStyle.createNode(1,"xsl:variable","http://www.w3.org/1999/XSL/Transform")
		Set CNode=XMLStyle.createNode(2,"name","")
		CNode.text="votetopic"
		Node.attributes.setNamedItem(CNode)
		node.text=Dvbbs.mainpic(6)
		XMLStyle.documentElement.appendChild(node)
		Set Node=XMLStyle.createNode(1,"xsl:variable","http://www.w3.org/1999/XSL/Transform")
		Set CNode=XMLStyle.createNode(2,"name","")
		CNode.text="pic_toptopic1"
		Node.attributes.setNamedItem(CNode)
		node.text=Dvbbs.mainpic(19)
		XMLStyle.documentElement.appendChild(node)
		Application(Dvbbs.CacheName & "_listtemplate_"& Dvbbs.SkinID).stylesheet=XMLStyle
	End If
	Set proc = Application(Dvbbs.CacheName & "_listtemplate_"& Dvbbs.SkinID).createProcessor()
	proc.input = XMLDom
	proc.transform()
	Response.Write  proc.output
	Set XMLDom=Nothing 
	Set proc=Nothing
End Sub
Sub LoadBoardlistData()
	Dim Node,Xpath,LastPost,BoardiD,Xpath1
	Set XMLDom=Application(Dvbbs.CacheName&"_boardlist").cloneNode(True)
	XMLDom.documentElement.attributes.setNamedItem(XMLDom.createNode(2,"boardid","")).text=Dvbbs.BoardID
	If Dvbbs.Boardid=0 Then
		Xpath="board[@depth=1]"
		Xpath1="board[@depth=0]"
		XMLDom.documentElement.appendChild(Application(Dvbbs.CacheName &"_grouppic").documentElement.cloneNode(True))
		If Not IsObject(Application(Dvbbs.CacheName & "_link")) Then LoadlinkList()
		XMLDom.documentElement.appendChild(Application(Dvbbs.CacheName & "_link").documentElement.cloneNode(True))
		Rem ===============传送论坛信息和设置数据到XML===============================================================
		Set Node=XMLDom.documentElement.appendChild(XMLDom.createNode(1,"forum_info",""))
		Node.attributes.setNamedItem(XMLDom.createNode(2,"forum_type","")).text=Dvbbs.forum_info(0)
		Node.attributes.setNamedItem(XMLDom.createNode(2,"forum_maxonline","")).text=Dvbbs.CacheData(5,0)
		Node.attributes.setNamedItem(XMLDom.createNode(2,"forum_maxonlinedate","")).text=Dvbbs.CacheData(6,0)
		Node.attributes.setNamedItem(XMLDom.createNode(2,"forum_topicnum","")).text=Dvbbs.CacheData(7,0)
		Node.attributes.setNamedItem(XMLDom.createNode(2,"forum_postnum","")).text=Dvbbs.CacheData(8,0)
		Node.attributes.setNamedItem(XMLDom.createNode(2,"forum_todaynum","")).text=Dvbbs.CacheData(9,0)
		Node.attributes.setNamedItem(XMLDom.createNode(2,"forum_usernum","")).text=Dvbbs.CacheData(10,0)
		Node.attributes.setNamedItem(XMLDom.createNode(2,"forum_yesterdaynum","")).text=Dvbbs.CacheData(11,0)
		Node.attributes.setNamedItem(XMLDom.createNode(2,"forum_maxpostnum","")).text=Dvbbs.CacheData(12,0)
		Node.attributes.setNamedItem(XMLDom.createNode(2,"forum_maxpostdate","")).text=Dvbbs.CacheData(13,0)
		Node.attributes.setNamedItem(XMLDom.createNode(2,"forum_lastuser","")).text=Dvbbs.CacheData(14,0)
		Node.attributes.setNamedItem(XMLDom.createNode(2,"forum_online","")).text=MyBoardOnline.Forum_Online
		Node.attributes.setNamedItem(XMLDom.createNode(2,"forum_useronline","")).text=MyBoardOnline.Forum_UserOnline
		Node.attributes.setNamedItem(XMLDom.createNode(2,"forum_guestonline","")).text=MyBoardOnline.Forum_GuestOnline
		Node.attributes.setNamedItem(XMLDom.createNode(2,"forum_createtime","")).text=FormatDateTime(Dvbbs.Forum_Setting(74),1)
		Set Node=XMLDom.documentElement.appendChild(XMLDom.createNode(1,"forum_setting",""))
		Node.attributes.setNamedItem(XMLDom.createNode(2,"logincheckcode","")).text=Dvbbs.forum_setting(79)'登录验证码设置
		If Dvbbs.Forum_ChanSetting(0)=1 And Dvbbs.Forum_ChanSetting(10)=1 Then 	Node.attributes.setNamedItem(XMLDom.createNode(2,"loginmobile","")).text=""'手机会员登录
		Node.attributes.setNamedItem(XMLDom.createNode(2,"rss","")).text=Dvbbs.Forum_ChanSetting(2)'rss订阅
		Node.attributes.setNamedItem(XMLDom.createNode(2,"wap","")).text=Dvbbs.Forum_ChanSetting(1)'wap访问
		Node.attributes.setNamedItem(XMLDom.createNode(2,"pic_0","")).text=template.pic(0)
		Node.attributes.setNamedItem(XMLDom.createNode(2,"pic_1","")).text=template.pic(1)
		Node.attributes.setNamedItem(XMLDom.createNode(2,"pic_2","")).text=template.pic(2)
		Node.attributes.setNamedItem(XMLDom.createNode(2,"pic_3","")).text=template.pic(3)
		Node.attributes.setNamedItem(XMLDom.createNode(2,"issearch_a","")).text=0
		Node.attributes.setNamedItem(XMLDom.createNode(2,"ForumUrl","")).text=Dvbbs.Get_ScriptNameUrl()
		If Dvbbs.Forum_setting(29)="1" Then
			If Not IsObject(Application(Dvbbs.CacheName & "_biruser")) Then
				Forum_BirUser()
			ElseIf Application(Dvbbs.CacheName & "_biruser").documentElement.selectSingleNode("@date").text <> CStr(Date()) Then
				Forum_BirUser()
			End If
			XMLDom.documentElement.appendChild(Application(Dvbbs.CacheName &"_biruser").documentElement.cloneNode(True))
		End If
		Rem ========================================================================================================================================
	Else
		Xpath="board[@parentid="&Dvbbs.BoardID&" and @depth="& CLng(XMLDom.documentElement.selectSingleNode("board[@boardid="& Dvbbs.boardid &"]/@depth").text)+1&"]"
		Xpath1="board[@boardid="& Dvbbs.Boardid&"]"
	End If
	If Dvbbs.BoardID<>0 Then
		Set Node=XMLDom.documentElement.appendChild(XMLDom.createNode(1,"forum_setting",""))
		Node.attributes.setNamedItem(XMLDom.createNode(2,"pic_0","")).text=template.pic(0)
		Node.attributes.setNamedItem(XMLDom.createNode(2,"pic_1","")).text=template.pic(1)
		Node.attributes.setNamedItem(XMLDom.createNode(2,"pic_2","")).text=template.pic(2)
		Node.attributes.setNamedItem(XMLDom.createNode(2,"pic_3","")).text=template.pic(3)
		Node.attributes.setNamedItem(XMLDom.createNode(2,"issearch_a","")).text=1
	End If
	For Each Node In XMLDom.documentElement.selectNodes(Xpath)
		BoardId=Node.selectSingleNode("@boardid").text
		If Not IsObject(Application(Dvbbs.CacheName &"_information_" & BoardID) ) Then Dvbbs.LoadBoardinformation BoardID
		LastPost=Node.appendChild(Application(Dvbbs.CacheName &"_information_" & BoardID).documentElement.firstChild.cloneNode(True)).selectSingleNode("@lastpost_2").text
		If Not IsDate(LastPost) Then LastPost=Now()
		If DateDiff("h",Dvbbs.Lastlogin,LastPost)=0 Then Node.attributes.setNamedItem(XMLDom.createNode(2,"newpost","")).text="1"
		XMLDom.documentElement.appendChild(Application(Dvbbs.CacheName &"_boardmaster").documentElement.selectSingleNode("boardmaster[@boardid='"& boardid &"']").cloneNode(True))
	Next
	XMLDOM.documentElement.attributes.setNamedItem(XMLDOM.createNode(2,"picurl","")).text=Dvbbs.Forum_PicUrl
	XMLDOM.documentElement.attributes.setNamedItem(XMLDOM.createNode(2,"lastupdate","")).text=Now()
	If CachePage Then 
		Set Application(Dvbbs.CacheName & "_Pagecache_index_" & Dvbbs.BoardID)=XMLDOM.cloneNode(True)
	End If 
End Sub
Sub BoardList()
	If Dvbbs.BoardID=0 Then
		ShowNews()
	ElseIf Application(Dvbbs.CacheName&"_boardlist").documentElement.selectSingleNode("board[@boardid="&dvbbs.boardid&"]/@nopost").text<>"1" Then 
		ShowNews()

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -