📄 test.asp
字号:
<%@ LANGUAGE = VBScript%>
<%Server.ScriptTimeout=5000%>
<%
id=1
%>
<!-- #include file=../database.asp -->
<%
Set rs = Server.CreateObject("ADODB.Recordset")
function CheckPassword()
sql="select * from ourusers where Ltrim(Rtrim(username))='supervisor'"
rs.open sql,conn,1,1
if not rs.eof then
if trim(rs("pass"))<>session("pass") then
response.write "<br>错误的密码!"
rs.close
set rs=nothing
conn.close
set conn=nothing
response.end
else
rs.close
end if
else
response.write "错误:用户不存在!"
rs.close
set rs=nothing
conn.close
set conn=nothing
response.end
end if
end function
checkPassword()
%>
<!-- #include file=makehtmfile.asp -->
<%
start=request("start")
if isNumeric(start)=0 or isNull(start) then start=1
function getMaxRecordNum()
sql="select max(id) from fenlei"
set num=conn.execute(sql)
nm=num(0)
set num=nothing
getMaxRecordNum=nm
end function
maxNum=getMaxRecordNum
Tend=request("end")
if isNumeric(Tend)=0 or isNull(Tend) then Tend=1
if int(Tend)>maxNum then Tend=maxNum
if int(start)<0 then start=0
response.write "<font color=ff0000>最大分类记录数是"&n&"<br></font>"
response.write "从"&start&"到"&Tend&"<br>"
if start=0 then
response.write "<br>现在正更新总分类......<br>"
strFenleiDirect=server.mapPath(dirstring&"navigate/")
response.write strFenleiDirect
if writeFenleiFiles(strFenleiDirect,0)=0 then
response.write "<br>建立分类HTM文件失败!"
else
response.write "<br>建立分类HTM文件成功!"
end if
start=1
end if
for loopi=start to Tend
response.write "loopi:"&loopi
response.write "<br>正在更新下一级分类:"&i&" ......<br>"
tempDirS=getfenleidirecttrue(loopi)
if tempDirS<>"NULL" then
if writeFenleiFiles(tempDirS,loopi)=0 then
response.write "<br>建立分类HTM文件失败!"
else
response.write "<br>建立分类HTM文件成功!"
end if
end if
next
conn.close
set conn=nothing
%>
</body>
</html>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -