终于把5U系统的目录缓冲速度忙问题解决
作者:admin 日期:2008-07-24
我的GAMEPZ.COM的1500目录问题解决了,再也不用为添加了目录后,更新缓冲等待那半年的时间了,具体解决方法:
1. 把下面代码,做成channel.asp 文件替换掉\inc\cache\文件夹下的channel.asp文件
程序代码
2,找到inc\function.asp,把设置目录缓冲的代码去掉,查找关键字"channel.asp"
这样就可以,直接把缓冲文件改成动态的了,记得第二步一顶要修改,不然很容易在以后日常操作中会把channel.asp文件替换掉。
总结:虽然会觉得在后台打开目录列表速度有点慢,但总比以前等上半天好多了!
1. 把下面代码,做成channel.asp 文件替换掉\inc\cache\文件夹下的channel.asp文件
程序代码<%
function getchannel(byval cid,byval datafield)
if len(cid) = 0 or not isnumeric(cid) or instr(cid,",") > 0 then cid = 0 else cid = int(cid)
dim rs2
set rs2 = db("select * from [{pre}channel] where id="&cid,1)
select case lcase(datafield)
case "id"
getchannel = rs2("id")
case "fatherid"
getchannel = rs2("FatherID")
case "childid"
getchannel = rs2("ChildID")
case "childids"
getchannel = rs2("ChildIDs")
case "name"
getchannel = rs2("Name")
case "table"
getchannel = rs2("Table")
case "domain"
getchannel = rs2("Domain")
case "outsidelink"
getchannel = rs2("OutSideLink")
case "templatechannel"
getchannel = installdir & templatedir & "/" & rs2("templatechannel")
case "templateclass"
getchannel = installdir & templatedir & "/" & rs2("templateclass")
case "templateview"
getchannel = installdir & templatedir & "/" & rs2("templateview")
case "ruleindex"
getchannel = replace(rs2("ruleindex"),"{installdir}",installdir)
case "rulechannel"
getchannel = replace(rs2("rulechannel"),"{cid}",rs2("id"))
case "ruleview"
getchannel = replace(rs2("ruleview"),"{cid}",rs2("id"))
case "picture"
getchannel = rs2("picture")
case "keywords"
getchannel = rs2("keywords")
case "description"
getchannel = rs2("description")
case else
getchannel = ""
end select
rs2.close : set rs2 = nothing
end function
%>
function getchannel(byval cid,byval datafield)
if len(cid) = 0 or not isnumeric(cid) or instr(cid,",") > 0 then cid = 0 else cid = int(cid)
dim rs2
set rs2 = db("select * from [{pre}channel] where id="&cid,1)
select case lcase(datafield)
case "id"
getchannel = rs2("id")
case "fatherid"
getchannel = rs2("FatherID")
case "childid"
getchannel = rs2("ChildID")
case "childids"
getchannel = rs2("ChildIDs")
case "name"
getchannel = rs2("Name")
case "table"
getchannel = rs2("Table")
case "domain"
getchannel = rs2("Domain")
case "outsidelink"
getchannel = rs2("OutSideLink")
case "templatechannel"
getchannel = installdir & templatedir & "/" & rs2("templatechannel")
case "templateclass"
getchannel = installdir & templatedir & "/" & rs2("templateclass")
case "templateview"
getchannel = installdir & templatedir & "/" & rs2("templateview")
case "ruleindex"
getchannel = replace(rs2("ruleindex"),"{installdir}",installdir)
case "rulechannel"
getchannel = replace(rs2("rulechannel"),"{cid}",rs2("id"))
case "ruleview"
getchannel = replace(rs2("ruleview"),"{cid}",rs2("id"))
case "picture"
getchannel = rs2("picture")
case "keywords"
getchannel = rs2("keywords")
case "description"
getchannel = rs2("description")
case else
getchannel = ""
end select
rs2.close : set rs2 = nothing
end function
%>
2,找到inc\function.asp,把设置目录缓冲的代码去掉,查找关键字"channel.asp"
这样就可以,直接把缓冲文件改成动态的了,记得第二步一顶要修改,不然很容易在以后日常操作中会把channel.asp文件替换掉。
总结:虽然会觉得在后台打开目录列表速度有点慢,但总比以前等上半天好多了!
评论: 0 | 引用: 0 | 查看次数: -
发表评论
上一篇
下一篇

文章来自:
Tags: