<!--#Include FILE="WapConfig/WapHeader.asp"-->
<%
'以下为文件正文。
'以下是数据库的设置信息
Dim ArticleID : ArticleID=Request.QueryString("ListID") 
If ArticleID<>"" Then Session("FindId")=ArticleID Else ArticleID=Session("FindId")
XML.StrSql="select * from SQ_Article where ArticleID=" & ArticleID
Dim BackList '定义返回上级的哪一类别。
BackList=XML.MdbShow("ClassId")

'虚线内为专题、搜索结果、文章显示的通用代码部分。
''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
'以下为查询相关路径问题。
ChannelID=XML.MdbShow("ChannelID")
XML.StrSql="Select * from SQ_Channel Where ChannelID=" & ChannelId
ChannelDir=XML.MdbShow("ChannelDir") '频道所在文件夹。
DownLoadPath=XML.MdbShow("ChannelDir") & "/" & XML.MdbShow("UploadDir") '上传文件所在的文件夹。

XML.StrSql="select * from SQ_Article where ArticleID=" & ArticleID
'显示标题
XML.WriteOut "<h2>" & XML.MdbShow("Title") & "</h2>"
XML.WriteOut "<ul><li>"
ShowContent=XML.MdbShow("CopyFrom") & " " & XML.MdbShow("Author") & " 浏览:" & XML.MdbShow("Hits") & "次 "
ShowContent=ShowContent & XML.MdbShow("WriteTime") & "<br/>"
ShowContent=ShowContent & XML.MdbShow("Content")
ShowContent=Replace(ShowContent,"[NextPage]","") '去掉动易的手工分页。

If XML.MdbShow("InfoPurview")=1 And Session("OnlineName")="" Then '当为会员时方可浏览。
	XML.WriteRow "这篇文章至少是本站的会员才可以阅读！"
	XML.WriteRow XML.A("登陆","Login.asp","立即登陆")
Else
	XML.AutoPage XML.DelHtml(ShowContent),TextLong,True,2
	If XML.MdbShow("UploadFiles")<>"" Then XML.WriteRow XML.A("","NewsPicShow.asp?ArticleID=" & ArticleID & "&amp;MyStart=" & Request("MyStart") & "&amp;ComeFrom=Search","查看本文插图")
End If

XML.WriteRow "更新时间:" & XML.MdbShow("UpdateTime") 
'XML.WriteRow "文章录入:" & XML.MdbShow("Inputer") '没必要显示，若感觉有必要，去掉最前的单引号。
'XML.WriteRow "责任编辑:" & XML.MdbShow("Editor") '没必要显示，若感觉有必要，去掉最前的单引号。 
XML.WriteRow "评论数:" & XML.A("查看","NewsComment.asp?ModuleType=1&amp;InfoID=" & ArticleID & "&amp;ComeFrom=Search",XML.MdbShow("CommentCount"))
If XML.RecordCount<1 Then XML.WriteRow "暂时没有您要找的信息。"

'更新浏览次数
XML.StrSql="Update SQ_Article set Hits=Hits+1 Where ArticleID=" & ArticleID
XML.MdbDo
''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
'以下关于上一条、下一条记录
XML.RsInfoPlace="None"
XML.ErrorPagePath=""
XML.FieldId="ArticleID"
XML.FieldShow="Title"
XML.GoFileName="NewsFindShow.asp"
If Session("ListOrder")="" Or Lcase(Session("ListOrder"))="desc" Then
	XML.WriteOut "下："
	XML.StrSql="Select Top 1 * from SQ_Article where ArticleID<" & ArticleID & " And Title Like '%" & Session("FindText") & "%' And ClassId=" & BackList & " And Status=3 Order By ArticleID Desc"
	XML.MdbList : If XML.RecordCount<1 Then XML.WriteRow "无"
	XML.WriteOut "上："
	XML.StrSql="Select Top 1 * from SQ_Article where ArticleID>" & ArticleID & " And Title Like '%" & Session("FindText") & "%' And ClassId=" & BackList & " And Status=3 Order By ArticleID Asc"
	XML.MdbList : If XML.RecordCount<1 Then XML.WriteRow "无"
Else
	XML.WriteOut "下："
	XML.StrSql="Select Top 1 * from SQ_Article where ArticleID>" & ArticleID & " And Title Like '%" & Session("FindText") & "%' And ClassId=" & BackList & " And Status=3 Order By ArticleID Desc"
	XML.MdbList : If XML.RecordCount<1 Then XML.WriteRow "无"
	XML.WriteOut "上："
	XML.StrSql="Select Top 1 * from SQ_Article where ArticleID<" & ArticleID & " And Title Like '%" & Session("FindText") & "%' And ClassId=" & BackList & " And Status=3 Order By ArticleID Asc"
	XML.MdbList : If XML.RecordCount<1 Then XML.WriteRow "无"
End If
XML.WriteOut "</li></ul>"
'以下为返回链接等
XML.WriteOut XML.Div(,,"N")
XML.WriteRow XML.ImgA("","NewsFindList.asp?Page=" & Session("MyPage"),"返回上级")
%>
<!--#Include FILE="WapConfig/WapFooter.asp"--> 
