sitemap.asp

来自「小游戏网站演示www.4399.io 拥有4万条游戏数据」· ASP 代码 · 共 78 行

ASP
78
字号
<!--#include file="../conn.asp"-->
<!--#include file="../inc/const.asp"-->
<!--#include file="../inc/classmenu.asp"-->
<%
dim htmlcontent
newasp.loadtemplates 9999, 7, 0

htmlcontent = newasp.htmlcontent
htmlcontent = replace(htmlcontent,"{$installdir}", newasp.installdir)
htmlcontent = replace(htmlcontent, "{$channelid}", 0)
htmlcontent = replace(htmlcontent,"{$pagetitle}",newasp.htmlsetting(5))
htmlcontent = readclassmenu(htmlcontent)
htmlcontent = readclassmenubar(htmlcontent)
htmlcontent = replace(htmlcontent,"{$tempcontent}", siteclassmap)
htmlcontent = replace(htmlcontent,"{$sitename}", newasp.sitename)
htmlcontent = replace(htmlcontent,"{$siteurl}", newasp.siteurl)
response.write htmlcontent
closeconn

public function siteclassmap()
	dim strtemp,classname
	dim sql,rs,i
	dim linktarget,strclass,thischanneldir,rssfeed
	linktarget = " target=""_blank"""
	strclass = " class=""menubar"""
	newasp.name = "siteclassmap"
	if newasp.objisempty() then
		sql = "select c.channelid,c.classid,c.depth,c.classname,c.readme,c.child,c.linktarget,c.turnlink,c.turnlinkurl,c.htmlfiledir,c.usehtml,c.showcount,b.channelname,b.channeldir,b.stopchannel,b.modulename,b.iscreatehtml,b.htmlextname,b.sortdestination,b.binddomain,b.domainname from [nc_classify] c inner join [nc_channel] b on c.channelid=b.channelid where b.stopchannel=0 order by c.channelid, c.rootid,c.orders"
		set rs = newasp.execute(sql)
		i = 0
		strtemp = newasp.htmlsetting(6)
		do while not rs.eof
			classname = rs("classname")
			if rs("turnlink") <> 0 then
				classname = "<a href=""" & rs("turnlinkurl") & """" & linktarget & strclass & ">" & classname & "</a>"
				rssfeed = "#"
			else
				if rs("binddomain") = 0 then
					thischanneldir = newasp.installdir & rs("channeldir")
				else
					thischanneldir = trim(rs("domainname")) &"/"
				end if
				rssfeed = thischanneldir & "rssfeed.asp?classid=" & rs("classid")
				if rs("iscreatehtml") <> 0 then
					thischanneldir = newasp.readdestination(rs("sortdestination"), rs("channeldir"), "",rs("htmlfiledir"),rs("classid"),1,1,"")
					if rs("binddomain") = 0 then
						thischanneldir = trim(rs("domainname")) & thischanneldir
					end if
					classname = "<a href=""" & thischanneldir & """" & linktarget & strclass & ">" & classname & "</a>"
				else
					if isurlrewrite then
						classname = "<a href=""" & thischanneldir & "list_1_" & rs("classid") & rs("htmlextname") & """" & linktarget & strclass & ">" & classname & "</a>"
					else
						classname = "<a href=""" & thischanneldir & "list.asp?classid=" & rs("classid") & """" & linktarget & strclass & ">" & classname & "</a>"
					end if
				end if
			end if
			if rs("depth") = 0 then
				if i > 0 then  strtemp = strtemp & newasp.htmlsetting(7)
				strtemp = strtemp & newasp.htmlsetting(8)
				strtemp = replace(strtemp, "{$classname}", classname)
			else
				strtemp = strtemp & newasp.htmlsetting(9)
				strtemp = replace(strtemp, "{$classname}", classname)
			end if
				strtemp = replace(strtemp, "{$classid}", rs("classid"))
				strtemp = replace(strtemp, "{$rssfeed}", rssfeed)
			rs.movenext
			i = i + 1
		loop
		strtemp = strtemp & newasp.htmlsetting(10)
		rs.close
		set rs = nothing
		newasp.value = strtemp
	end if
	siteclassmap = newasp.value
end function
%>

⌨️ 快捷键说明

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