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

📄 create_softindexcls1.asp

📁 大型黄页系统,精美黄页flash演示,10m
💻 ASP
📖 第 1 页 / 共 3 页
字号:
			Rs.Close

			HtmlString = HtmlString & "</TD>" & vbCrLf
			If DownsysClass.TempSet(12) = "" Then
				If (i Mod 2) = 1 Then HtmlString = HtmlString & "</tr><tr>"
			Else
				If (i Mod CInt(DownsysClass.TempSet(12))) = (CInt(DownsysClass.TempSet(12)) - 1) Then HtmlString = HtmlString & "</tr><tr>"
			End If
		Next
		HtmlString = HtmlString & " </TR>" & vbCrLf
		HtmlString = HtmlString & "</TABLE>" & vbCrLf
		Set Rs = Nothing
		CreateSoftType = HtmlString
	End Function
	'*************************************************************
	'函数作用:图片推荐
	'*************************************************************
	Private Function SoftImage()
		Dim Rs, SQL, HtmlString, SoftName, SoftImg, i
		Set Rs = Server.CreateObject("adodb.recordset")
		SQL = "select Top " & CInt(DownsysClass.TempSet(0)) & " softid,sortid,SoftName,SoftVer,SoftImg from NC_SoftInfo where isLock = 0 And SoftImg <>'' order by SoftTime desc, softid desc"
		Rs.Open SQL, Conn, 1, 1
		If Rs.bof And Rs.EOF Then
			HtmlString = "<TABLE class=picstyle cellSpacing=0 cellPadding=0 width=64  border=0><TBODY><TR><TD align=middle height=64><img src='" & DownsysClass.SetupDir & "images/NoPic.jpg' onload='javascript:if(this.height>this.width){this.height=" & DownsysClass.TempSet(14) & "}else{this.width=" & DownsysClass.TempSet(13) & "}'  border='0'></TD></TR></TBODY></TABLE>"
		Else
			HtmlString = DownsysClass.TempSet(2)
			Do While Not Rs.EOF
				If CInt(DownsysClass.Setting(5)) = 0 Then
					SoftName = "<A HREF='" & DownsysClass.SetupDir & "Software/Catalog" & Rs(1) & "/" & Rs(0) & ".html' title='" & Rs(2) & Rs(3) & "'>" & DownsysClass.gotTopic(Rs(2) & " " & Rs(3), CInt(DownsysClass.TempSet(1))) & "</A>"
					SoftImg = "<TABLE class=picstyle cellSpacing=0 cellPadding=0 width=64  border=0><TBODY><TR><TD align=middle height=64><A HREF='" & DownsysClass.SetupDir & "Software/Catalog" & Rs(1) & "/" & Rs(0) & ".html' title='" & Rs(2) & Rs(3) & "'><img src='" & Rs(4) & "' onload='javascript:if(this.height>this.width){this.height=" & DownsysClass.TempSet(14) & "}else{this.width=" & DownsysClass.TempSet(13) & "}'  border='0'></A></TD></TR></TBODY></TABLE>"
				Else
					SoftName = "<A HREF='" & DownsysClass.SetupDir & "Software.asp?id=" & Rs(0) & "' title='" & Rs(2) & " " & Rs(3) & "'>" & DownsysClass.gotTopic(Rs(2) & " " & Rs(3), CInt(DownsysClass.TempSet(1))) & "</A>"
					SoftImg = "<TABLE class=picstyle cellSpacing=0 cellPadding=0 width=64  border=0><TBODY><TR><TD align=middle height=64><A HREF='" & DownsysClass.SetupDir & "Software.asp?id=" & Rs(0) & "' title='" & Rs(2) & " " & Rs(3) & "'><img src='" & Rs(4) & "' onload='javascript:if(this.height>this.width){this.height=" & DownsysClass.TempSet(14) & "}else{this.width=" & DownsysClass.TempSet(13) & "}'  border='0'></A></TD></TR></TBODY></TABLE>"
				End If
				HtmlString = HtmlString & DownsysClass.TempSet(3)
				HtmlString = Replace(HtmlString, "{$SoftImage}", SoftImg)
				HtmlString = Replace(HtmlString, "{$SoftName}", SoftName)
				Rs.movenext
			Loop
			HtmlString = HtmlString & DownsysClass.TempSet(4)
		End If
		Rs.Close
		Set Rs = Nothing
		SoftImage = HtmlString
	End Function

	Private Function CreateHtmlFile()
		DownsysClass.LoadTemplates ("index")
		Dim DownloadClass_Ads
		Set DownloadClass_Ads = New Adcolumn_Cls
		Dim temphtml, NowStats, HtmlTitle
		Dim TempTopStr, TempFootStr
		NowStats = "首页"
		HtmlTitle = "首页"
		If Len(DownsysClass.temphtml(0)) < 50 Then
			TempTopStr =   DownsysClass.mainhtml(2) 
		Else
			TempTopStr =  DownsysClass.mainhtml(0) &  DownsysClass.mainhtml(2) 
		End If
		If Len(DownsysClass.temphtml(5)) = 0 Then
			TempFootStr = DownsysClass.mainhtml(4)
		Else
			TempFootStr = DownsysClass.temphtml(5)
		End If
		temphtml = TempTopStr & DownsysClass.temphtml(1) & DownsysClass.temphtml(2) & DownsysClass.temphtml(3) & DownsysClass.temphtml(4) & TempFootStr
		temphtml = Replace(temphtml, "{$NavMenu}", DownsysClass.SortingMenu)
		temphtml = Replace(temphtml, "{$Width}", DownsysClass.mainset(0))
		If CInt(DownsysClass.Setting(5)) = 0 Then
			temphtml = Replace(temphtml, "{$TopMeun}", DownsysClass.mainset(9))
		Else
			temphtml = Replace(temphtml, "{$TopMeun}", DownsysClass.mainset(10))
		End If
		If CInt(DownsysClass.Setting(5)) = 1 Then
			temphtml = Replace(temphtml, "{$FootMeun}", DownsysClass.mainset(11))
		Else 
			temphtml = Replace(temphtml, "{$FootMeun}", DownsysClass.mainset(44))
		End If
		temphtml = Replace(temphtml, "{$Style_CSS}", DownsysClass.Style_CSS)
		temphtml = Replace(temphtml, "{$NowStats}", NowStats)
		temphtml = Replace(temphtml, "{$Title}", HtmlTitle)
		temphtml = Replace(temphtml, "{$NewArticle}", NewArticle)
		temphtml = Replace(temphtml, "{$BestArticle}", BestArticle)
		temphtml = Replace(temphtml, "{$DayNewSoft}", DayNewSoft)
		temphtml = Replace(temphtml, "{$CommendSoft}", CommendSoft)
		temphtml = Replace(temphtml, "{$Message}", WebMessage(1))
		temphtml = Replace(temphtml, "{$Statistic}", Statistics)
		temphtml = Replace(temphtml, "{$SoftImage}", SoftImage)
		temphtml = Replace(temphtml, "{$SoftType}", CreateSoftType)
		temphtml = Replace(temphtml, "{$FriendLink}", FriendLink)
		temphtml = Replace(temphtml, "{$Catalog}", CatalogInfo)
		temphtml = Replace(temphtml, "{$hangye}", hangye)
		temphtml = Replace(temphtml, "{$sousuo}", sousuo)
		temphtml = Replace(temphtml, "{$Adcolumn(0)}", DownloadClass_Ads.ScriptFixedAds(1))
		temphtml = Replace(temphtml, "{$Adcolumn(1)}", DownloadClass_Ads.tuijianAds(1))
		temphtml = Replace(temphtml, "{$Adcolumn(2)}", DownloadClass_Ads.AdsColumn(1, 2))
		temphtml = Replace(temphtml, "{$Adcolumn(3)}", DownloadClass_Ads.AdsColumn(1, 3))
		temphtml = Replace(temphtml, "{$Adcolumn(6)}", DownloadClass_Ads.AdsColumn(1, 7))
		temphtml = Replace(temphtml, "{$Adcolumn(4)}", DownloadClass_Ads.ScriptFloatAds(1))
		temphtml = Replace(temphtml, "{$Adcolumn(5)}", DownloadClass_Ads.ScriptFixedAds(1))
		Set DownloadClass_Ads = Nothing
		CreateHtmlFile = temphtml
	End Function
	
	'搜索下拉框选择项目(整体分类部分:供应、求购)
Private Function sousuo()
Dim SoftType
Dim HtmlShowPage
Dim ii
			HtmlShowPage = HtmlShowPage &" <select name=""action""> "
            HtmlShowPage = HtmlShowPage &" <option value=""soft"" selected>全部信息</option>"
			SoftType = Split(DownsysClass.Setting(35), ",")
			For ii = 0 To UBound(SoftType)
			HtmlShowPage = HtmlShowPage & "<option value=""soft"& ii &""">" & Trim(SoftType(ii)) & "</option>"
			Next
			HtmlShowPage = HtmlShowPage & "<option value=""info"">文章搜索</option></SELECT>"
	sousuo = HtmlShowPage
End Function
'行业下拉框选择项目
Private Function hangye()
Dim rs2,sql2,HtmlShowPage
			HtmlShowPage = HtmlShowPage &" <SELECT name=CategoryId id=""CategoryId""> "
            HtmlShowPage = HtmlShowPage &" <OPTION value='0' selected>=选择行业=</OPTION>"
					set rs2=server.createobject("adodb.recordset")
					sql2="select * from NC_SoftSort where depth=0 order by sortid "
					rs2.open sql2,conn,1,3
					do while not rs2.EOF
			HtmlShowPage = HtmlShowPage & "<option value='"& rs2("rootid") &"'>"& trim(rs2("SortName")) &"</option>"
					rs2.MoveNext
					loop
					Rs2.Close
			HtmlShowPage = HtmlShowPage & "</SELECT>"
	hangye = HtmlShowPage
End Function
	'*************************************************************
	'函数作用:分类列表
	'*************************************************************
Private Function CatalogInfo()
	Dim Rs
	Dim Rs_c
	Dim HtmlString
	Dim TotalNumber
	Dim TotalNum
	Dim i,m
	Set Rs = CreateObject("adodb.recordset")
	Set Rs_c = CreateObject("adodb.recordset")
	HtmlString = HtmlString & "<TABLE width=""100%""  cellSpacing=0 cellPadding=0  border=0>" & vbCrLf

	Rs.Open "select * from NC_softSort Where depth = 0 order by sortid asc", conn, 1, 1
	If Not (Rs.bof And Rs.EOF) Then
		Do While Not Rs.EOF
		for m = 1 to 2
		if not Rs.eof then
			HtmlString = HtmlString & " <td><table><TR>" & vbCrLf
			HtmlString = HtmlString & "    <TD width=""50%"" class=paddlefthome>"
			If CInt(DownsysClass.Setting(5)) = 0 Then
				HtmlString = HtmlString & "<a href='" & DownsysClass.SetupDir & "Sorting0/Catalog" & Rs("sortid") & "/Sorting_Indate_Desc_1.html' title='" & Rs("readme") & "<BR>共有信息:" & Rs("SoftNum") & " 个'><b>" & Rs("sortName") & "</b></a> "
			Else
				HtmlString = HtmlString & "<a href='" & DownsysClass.SetupDir & "Sorting.Asp?sortid=" & Rs("sortid") & "' title='" & Rs("readme") & "<BR>共有信息:" & Rs("SoftNum") & " 个'>" & Rs("sortName") & "</a> "
			End If
			HtmlString = HtmlString & "</TD></tr><tr><TD width=""100%"" class=paddhome>" & vbCrLf
			'二级目录循环开始
			Rs_c.Open "select top 3 * from NC_softSort where depth = 1 and rootid=" & Rs("rootid") & " order by sortid asc", conn, 1, 1
			If Rs_c.bof And Rs_c.EOF Then
				HtmlString = HtmlString & "没有添加分类"
			Else
				TotalNumber = Rs_c.recordcount
				i = 1
				Do While Not Rs_c.EOF
					If CInt(DownsysClass.Setting(5)) = 0 Then
						HtmlString = HtmlString & "<a href='" & DownsysClass.SetupDir & "Sorting0/Catalog" & Rs_c("sortid") & "/Sorting_Indate_Desc_1.html' title='" & Rs_c("readme") & "<BR>共有信息:" & Rs_c("SoftNum") & " 个'>" & Rs_c("sortName") & "</a> &nbsp; " & vbCrLf
					Else
						HtmlString = HtmlString & "<a href='" & DownsysClass.SetupDir & "Sorting.Asp?sortid=" & Rs_c("sortid") & "' title='" & Rs_c("readme") & "<BR>共有信息:" & Rs_c("SoftNum") & " 个'>" & Rs_c("sortName") & "</a> &nbsp; " & vbCrLf
					End If
					If (i Mod CInt(DownsysClass.mainset(28))) = 0 And i <> TotalNumber Then
						HtmlString = HtmlString & " <br></tr>"
					End If
					i = i + 1
					Rs_c.movenext
				Loop
			End If
			Rs_c.Close
'二级目录循环结束
			
			HtmlString = HtmlString & " </TR></table>"
			Rs.movenext
'分列排序,开始
		else
				HtmlString = HtmlString & " </TR>" & vbCrLf
				HtmlString = HtmlString & "    <td height=1></td>"
		end if
		next
				HtmlString = HtmlString & " </TR>" & vbCrLf
				HtmlString = HtmlString & " <tr><td height=1></td></tr><tr >"
		Loop
	End If
	Rs.Close
	Set Rs_c = Nothing
	Set Rs = Nothing
	CatalogInfo = HtmlString
End Function
	
		Public Sub Init_IndexHtml()
		Response.Buffer = True
		Dim CreateHtml, FSO, Fout
		Set NC_Admin = New Check
		NC_Admin.AdminChk = "31"
		NC_Admin.Check
		DownsysClass.admin_header
		If Not(DownsysClass.IsObjectFSO(DownsysClass.Script_FSO) And CInt(DownsysClass.Setting(5)) = 0 ) Then
			NC_Admin.Error_Msg ("<b><font color=red>你的服务器不支持 FSO(Scripting.FileSystemObject)或你后台没有选择为html方式</font></b>")
			DownsysClass.admin_footer
			Response.End
		End If
		Set FSO = Server.CreateObject("ADODB.STREAM")
		CreateHtml = Server.MapPath(DownsysClass.SetupDir & DownsysClass.Setting(6))
		With FSO
			.Open
			.Charset = "GB2312"
			.WriteText CreateHtmlFile
			.SaveToFile CreateHtml,2
			.Close
		End With
		Set FSO = Nothing
		NC_Admin.Succeed_Msg ("生成供求信息首页成功!")
		DownsysClass.admin_footer
	End Sub

	Public Sub IndexHtml()
		Response.Buffer = True
		If CInt(DownsysClass.Setting(5)) = 0 Then
			Response.redirect (DownsysClass.SetupDir & DownsysClass.Setting(6))
		Else
			Response.Write CreateHtmlFile
		End If
	End Sub

End Class
%>

⌨️ 快捷键说明

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