%
Call SiteInfo()
If ISHTML = 1 Then
Response.expires = 0
Response.expiresabsolute = Now() - 1
Response.addHeader "pragma", "no-cache"
Response.addHeader "cache-control", "private"
Response.CacheControl = "no-cache"
End If
ID = request.QueryString("ID")
If ID <> "" Or IsNumeric(ID) Then
Set rs = server.CreateObject("Adodb.Recordset")
sql = "Select * From Qianbo_News Where ViewFlag And ID = " & ID
rs.Open sql, conn, 1, 3
If rs("SeoKeywords") <> "" Then
SeoKeywords = rs("SeoKeywords")
Else
SeoKeywords = rs("NewsName")
End If
If rs("SeoDescription") <> "" Then
SeoDescription = rs("SeoDescription")
Else
SeoDescription = rs("NewsName")
End If
SeoTitle = rs("NewsName")
SortPath = rs("SortPath")
AddTime = rs("AddTime")
Content = rs("Content")
End If
rs.Close
Set rs = Nothing
%>
<%
Function WebMenu()
Dim rs, sql
Set rs = server.CreateObject("Adodb.Recordset")
sql = "Select * From Qianbo_NewsSort Where ViewFlag And ParentID <> 0 Order By ID Asc"
rs.Open sql, conn, 1, 1
If Not rs.EOF Then
Do
If ISHTML = 1 Then
AutoLink = "" & NewSortName & Separated & rs("ID") & Separated & "." & HTMLName & ""
Else
AutoLink = "NewsList.Asp?SortID=" & rs("ID") & ""
End If
If SortPath = rs("SortPath") Then
tmpCss = " current-menu-item"
Else
tmpCss = ""
End If
Response.Write "
"
If Request.QueryString("ID") = "" Then
WebLocation = WebLocation
ElseIf Not IsNumeric(Request.QueryString("ID")) Then
WebLocation = WebLocation & "读取错误"
ElseIf conn.Execute("Select * From Qianbo_News Where ViewFlag And ID = " & Request.QueryString("ID")).EOF Then
WebLocation = WebLocation & "读取错误"
Else
Dim rs, sql
Set rs = server.CreateObject("Adodb.Recordset")
sql = "Select * From Qianbo_News Where ViewFlag And ID = " & Request.QueryString("ID")
rs.Open sql, conn, 1, 1
WebLocation = WebLocation & SortPathTXT("Qianbo_NewsSort", rs("SortID"))
rs.Close
Set rs = Nothing
End If
End Function
Function SortPathTXT(DataFrom, ID)
Dim rs, sql
Set rs = server.CreateObject("Adodb.Recordset")
sql = "Select * From " & DataFrom & " where ViewFlag And ID = " & ID
rs.Open sql, conn, 1, 1
If Not rs.EOF Then
If ISHTML = 1 Then
AutoLink = "" & NewSortName & "" & Separated & "" & rs("ID") & "" & Separated & "1." & HTMLName & ""
Else
AutoLink = "NewsList.Asp?SortID = " & rs("ID") & ""
End If
SortPathTXT = SortPathTXT(DataFrom, rs("ParentID")) & "