?? new.asp
字號:
<%@LANGUAGE="VBSCRIPT" CODEPAGE="936"%>
<!--#include file="admin/BBSConfig.asp"-->
<%
bbsPath = "" '論壇在根目錄請留空,否則請輸入論壇所在空間文件夾名,請在論壇所在文件夾名前后加"/",比如:bbsPath = "/bbs/"
action = trim(request.QueryString("action"))
n = trim(request.QueryString("n"))
if not(IsNumeric(n)) then n = 10
if action = "new" then
sql = "select top "& n &" threadID,thread_title,posttime,pollid,openpost,bestpost,displayorder,toppost,replycount,viewcount,postuserid,postusername,lastpost,lastposterid,lastposter,lastcontent,moveid,icons,rating from JBB_thread order by lastpost desc"
else
sql = "select top "& n &" threadID,thread_title,posttime,pollid,openpost,bestpost,displayorder,toppost,replycount,viewcount,postuserid,postusername,lastpost,lastposterid,lastposter,lastcontent,moveid,icons,rating from JBB_thread order by viewcount desc"
End if
set rs = server.CreateObject("adodb.recordset")
rs.open sql,conn,1,1
if Not(rs.eof and rs.bof) then
response.write"document.write('<table width=""100%"" border=""0"" align=""center"" cellspacing=""1"">');"
for i = 1 to n
if rs.eof then exit for
response.write"document.write('<tr><td width=18>');"
if trim(rs("icons")) <> 0 then
response.write"document.write('<img src="""&bbsPath&"images/posticon/icon"& trim(rs("icons")) &".gif"">');"
End if
if rs("moveid") > 0 then
threadURL = rs("moveid")
else
threadURL = rs("threadID")
End if
response.write"document.write('</td><td><a href="""&bbsPath&"showthread.asp?threadid="& threadURL &""" target=""_blank"">"& rtrim(rs("thread_title")) &"</a>');"
if rs("postuserID") <> 0 then
response.write"document.write(' [<a href="""&bbsPath&"user.asp?userID="& rs("postuserID") &""" target=""_blank"">"& rtrim(rs("postusername")) &"</a>]');"
else
response.write"document.write(' [游客]');"
End if
response.write"document.write('</td></tr>');"
rs.MoveNext
Next'i
response.write"document.write('</table>');"
End if
rs.close
set conn = nothing
%>
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -