📄 forum_boardjing.asp
字号:
<!--#include file=INC/skin.asp-->
<!--#include file=INC/Forum_bbsfun.asp-->
<%
dim const_txl_HomeUrl,errstr,i,BoardID,BoardName,boardexist,page
errstr=""
boardexist=false
const_txl_HomeUrl=""
BoardID=Request.QueryString("BoardID")
IF BoardID="" or (not isnumeric(BoardID)) Then
Response.Redirect("index.asp")
Response.End
End IF
call OpenDatabase
getBoardName
call txl_SiteHead(const_txlname&"-影音论坛-"&BoardName)
Response.Flush()
call online
Call main
Response.Flush()
call CloseDatabase
call web_end
Response.Flush()
Sub main
If const_bbs_login_limit=1 Then '论坛登录查看限制
If session("username")="" Then
errstr="<li>当前Wap影音状态已经设置为<font color=red>影音论坛只有登录之后才能看到</font>!</li>"
errstr=errstr&"<li>你现在还没有登录或者会话超时,点<a href='user_login.asp'>这里登录</a>!</li>"
errstr=errstr&"<li>如果还有疑问请与管理员联系!</li>"
Call printerror("查看影音论坛出错!",errstr,779)
Exit Sub
End If
ElseIf const_bbs_login_limit=2 Then
If session("username")="" Then
errstr="<li>当前Wap影音状态已经设置为<font color=red>影音论坛只有影音成员和嘉宾有查看权限</font>!</li>"
errstr=errstr&"<li>你现在还没有登录或者会话超时,点<a href='user_login.asp'>这里登录</a>!</li>"
errstr=errstr&"<li>如果还有疑问请与管理员联系!</li>"
Call printerror("查看影音论坛出错!",errstr,779)
Exit Sub
End If
If not (session("usertype")=3 or session("usertype")=4) Then
errstr="<li>当前Wap影音状态已经设置为<font color=red>影音论坛只有影音成员和嘉宾有查看权限</font>!</li>"
errstr=errstr&"<li>你目前的身份没有该权限!</li>"
errstr=errstr&"<li>如果还有疑问请与管理员联系!</li>"
Call printerror("查看影音论坛出错!",errstr,779)
Exit Sub
End If
End If
IF not boardexist then
dim errstr
errstr="<li>不存在标号为"&BoardID&"的论坛版面,该版面可能已经被删除</li>"
errstr=errstr&"<li>请选择<a href='index.asp'>影音论坛</a>重新进入论坛版面</li>"
Call printerror("读取论坛版面出错",errstr,779)
exit sub
end if
Dim rs,sql,title,RecordCount2,CurrentPage,PageSize2,LinkFile,displaypagenum,PageCount2,tmpnum
page=Request.QueryString("page")
if page="" or (not isnumeric(page)) Then
page=1
end if
page=Cint(page)
%>
<table width="779" border="0" cellspacing="0" cellpadding="0" align="center">
<tr>
<td background="" style="padding:5px;vertical-align:top; ">
<table width="100%" border="0" cellspacing="5" cellpadding="0">
<tr>
<td colspan="2" class="rig1"><b>当前位置: <a href="<%=const_homepageurl%>">首页</a> >> <a href="<%=const_txl_HomeUrl&const_txlurl%>"><%=const_txlname%></a> >> <a href="forum.asp">影音论坛</a> >><a href="Forum_BoardList.asp?boardid=<%=boardid%>"><%=BoardName%></a>
</b></td>
<td height="25" bgcolor="#FFFFFF" class="more">
<marquee direction="left" loop="-1" scrollamount="2" width="100" onMouseOver="this.stop()" onmouseout="this.start()"><%Call BBSNotic(BoardID)%></marquee>
</td>
</tr>
</table>
<table width="100%" border="0" cellpadding="0" cellspacing="5" class="liu">
<tr>
<td bgcolor="#FFFFFF"><a href="Forum_newannounce.asp?boardid=<%=boardid%>"><img src="images/newanc.gif" alt="发布新帖" width="60" height="17" border="0" align="absmiddle"></a> <a href="Forum_BoardList.asp?boardid=<%=boardid%>">帖子列表</a></td>
<td width="458" align="right" bgcolor="#FFFFFF">版主:
<%Call showbbsmaster(boardid)%>
</td>
</tr>
</table>
<table width="100%" border="1" cellpadding="1" cellspacing="0" bordercolor="#CCCCCC" bgcolor="#FFFFFF" class="liu">
<tr bgcolor="#576F9F">
<td height="25" width="3%" style="text-align:center;color:#FFFFFF; font-weight:bold;line-height:1.5;">ID</td>
<td width="35%" style="text-align:center;color:#FFFFFF; font-weight:bold;line-height:1.5;">主题</td>
<td width="10%" style="text-align:center;color:#FFFFFF; font-weight:bold;line-height:1.5;">作者</td>
<td width="6%" style="text-align:center;color:#FFFFFF; font-weight:bold;line-height:1.5;">人气</td>
<td width="19%" style="text-align:center;color:#FFFFFF; font-weight:bold;line-height:1.5;">发表时间</td>
<td width="29%" style="text-align:center;color:#FFFFFF; font-weight:bold;line-height:1.5;">最后回复</td>
</tr>
<%
PageSize2=20
set rs=Server.CreateObject("Adodb.Recordset")
sql="select * from Announce where parentID=0 and goodflag=1 and boardid="&boardid&" order by id desc"
rs.open sql,conn,1
Call displayAnnouncelist(rs,3,pagesize2)
RecordCount2=rs.recordcount
LinkFile="?boardid="&boardid&"&"
displaypagenum=10
rs.pagesize=PageSize2
If not rs.eof then
rs.absolutepage=page
end if
%>
<tr>
<td colspan="6">
<table width="100%" border="0" cellspacing="8" cellpadding="0">
<tr>
<td width="80%"><%=ShowPage(PageCount2,RecordCount2,page,PageSize2,LinkFile,displaypagenum) %>
</td>
<td width="20%"><%Call changeboard%>
</td>
</tr>
</table> </td>
</tr>
</table></td>
</tr>
</table>
<%
rs.close
set rs=nothing
End Sub
%>
<%sub displayAnnouncelist(Byref rs,topflag,byref pagesize2)
dim title,imgsrc,i,isjinghua
select case topflag
case 1:imgsrc="intop.gif"
case 2:imgsrc="alltop.gif"
case 3:imgsrc="tpc.gif"
end select
i=0
while not rs.eof and i<pagesize2
i=i+1
title=rs("title")
if len(title)>30 Then title=left(title,28)&"……"
if rs("goodflag")=1 Then
isjinghua=" <img src='images/jh.GIF' border='0' align='absmiddle' title='此帖为精华帖'>"
else
isjinghua=""
end if
%>
<tr>
<td align="center"><img src="images/<%=imgsrc%>" width="18" height="18"></td>
<td class="content"> <a href="Announce.asp?boardid=<%=rs("boardid")%>&announceid=<%=rs("ID")%>" title="<%=rs("lastinfo")%>"><%=title%></a><%=isjinghua%></td>
<td align="center" class="content"><%=getmasterusername(rs("username"))%></td>
<td align="center" class="content"><%=rs("replys")&"/"&rs("hits")%></td>
<td align="center" class="content"><span class="small"><%=rs("ndatetime")%></span></td>
<td align="center" class="content"><%=getmasterusername(rs("lastuser"))%>(<span class="small"><%=rs("lasttime")%></span>)</td>
</tr>
<%
rs.movenext
wend
End sub
%>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -