makedetail.asp
来自「网胜B2B电子商务蓝色风格2008SP6.0.1普及版」· ASP 代码 · 共 129 行
ASP
129 行
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charSet=gb2312">
<title>生成帮助信息详细页</title>
<style type="text/css">
<!--
body {
margin-left: 0px;
margin-top: 0px;
margin-right: 0px;
margin-bottom: 0px;
background-color: #E4EDF9;
}
body,td,th {
font-size: 12px;
}
-->
</style>
</head>
<body>
<%
data_path="../../../" 'ACC连接数据库路径,对SQL无效
dir="no"
numid="no"
%>
<!--#include file="../../../conn/conn.asp"-->
<!--#include file="../../../inc/safe.asp"-->
<!--#include file="../../../inc/filesystem.asp"-->
<!--#include file="../index/temp_inc.asp"-->
<!--#include file="../makerole.asp"-->
<%
Set rs=Server.CreateObject("adodb.recordSet")
rs.Open ("select help_detail from [Websen_worldec_Temp] where yx_selected=1"),conn,1,1
If rs.Eof Then
Response.Write("<br><br> <font color=red>对不起!该模版不存在!</font><a href='#' onclick='javascript:window.close();'>关闭</a>")
Response.End()
End If
If Not rs.Eof Then
pencat=rs("help_detail")
rs.Close
End If
If Request("page")<>"" Then
If Cint(Request("page"))<1 Then
currentPage=1
Else
currentPage=Cint(Request("page"))
End If
Else
currentPage=1
End If
If Request("TopNew")>"" Then
If ChkRequest(Request("TopNew")) Then
TopNew=Request("TopNew")
Else
Response.Redirect (HOPE_InstallDir&"login/chklogin.asp?login=4")
End If
End If
MaxPerPage=1
Set rs=Server.CreateObject("adodb.recordSet")
If Request("all")="all" Then
rs.Open ("select * from Websen_help order by dateandtime asc"),conn,1,1
ElseIf Request("all")="update" Then
If Request("schtml")="开始生成从未生成的" Then
rs.Open ("select * from Websen_help where html_pass=0 order by dateandtime asc"),conn,1,1
Else
id1=replace(Request("id1"),"'","")
id2=replace(Request("id2"),"'","")
If isnumeric(id2)=false or isnumeric(id2)=false Then Response.Write "ID应用数字" :Response.End
rs.Open ("select * from Websen_help where id between "&id1&" and "&id2&" order by dateandtime asc"),conn,1,1
End If
End If
If Not rs.Eof Then
rs.Pagesize=MaxPerPage
mpage=rs.Pagecount
If TopNew>"" Then
currentPage=mpage-TopNew
End If
If currentPage>mpage Then
Response.Write "<b>生成完毕</b> 完成时间:"&Now()
Response.End
End If
rs.Move (currentPage-1)*MaxPerPage
If mpage>=currentPage Then
ttid=rs("id")
sortid=rs("sortid")
typeid=rs("typeid")
End If
Else
Response.Write "没有生成信息"
Response.End
End If
sqltype="select * from Websen_help_type where typeid="&typeid&""
Set rstype=Server.CreateObject("ADODB.Recordset")
rstype.Open sqltype,conn,1,1
If Not rstype.Eof Then
HOPE_Sort="<a href="""&HOPE_InstallDir&"help/bin/info/"&rstype("sortid")&"-"&rstype("typeid")&".html""><b>"&rstype("typename")&"</b></a>"
Else
HOPE_Sort=""
rstype.Close
End If
HOPE_Title=rs("showname")
HOPE_body=rs("content")
Response.Write "<br><b>已生成/要生成的页面条数:<font color=#FF0000>"¤tPage-1&"</font>/<font color=#FF0000><b>"&mpage&"</b></font>个"
If mpage<currentPage Then
Response.Write ",完成时间"&Now()&"</b> "
Else
pencat=Hope_HtmlResult(pencat)
conn.execute("update Websen_help Set html_pass=1 where id="&ttid&"")
Set fso = YXFSO
Set sort_save = fso.CreateTextFile(Server.Mappath(HOPE_InstallDir&"help/bin/detail/"&sortid&"-"&typeid&"-"&ttid&".html"))
sort_save.Write pencat
sort_save.Close
Response.Write "<meta http-equiv=Refresh content='0; URL=makedetail.asp?all="&Request("all")&"&id1="&id1&"&id2="&id2&"&page="¤tPage+1&"&schtml="&Request("schtml")&"'>"
End If
Set rs=Nothing
conn.Close
Set conn=Nothing
%>
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?