📄 elist.jsp
字号:
<%@ page contentType="text/html;charset=GBK"%>
<%@ page import="com.bcxy.bbs.forum.*,java.util.Vector"%>
<%@ include file="INC/const.jsp"%>
<%
int perPage=ParamUtil.getInt(request,"perPage",20);
int Page=ParamUtil.getInt(request,"Page",1);
int startPage=((Page-1)/10)*10+1;
int listPerPage = ParamUtil.getInt(request, "listPerPage", 10);
try{
Forum theForum=ForumFactory.getForum(request,response,session,forumID);
stats=theForum.getForumType();
%>
<%@ include file="INC/theme.jsp"%>
<script language=javascript src="INC/list.js"></script>
<%
if(theForum.getForumSkin()==5){
if ("".equals(userName)){
throw new Exception("本论坛为认证论坛,请<a href=login.jsp>登陆</a>并确认您的用户名已经得到管理员的认证后进入。");
}
else{
if(!(theForum.getForumUser().indexOf(userName)>=0 || forumMaster || master)){
throw new Exception("本论坛为认证论坛,请确认您的用户名已经得到管理员的认证后进入。");
}
}
}else if(theForum.getForumSkin()==6){
if ("".equals(userName)){
throw new Exception("正规论坛,只有<a href=login.jsp><font color="+tableContentColor+">登陆用户</font></a>才能浏览论坛并发言");
}
}
out.println(headLine(forumID,forumName,forumLogo,theForum.getForumType(),1,stats,tableWidth));
%>
<TABLE cellSpacing=0 cellPadding=0 width=<%=tableWidth%> border=0 align=center>
<TBODY><tr>
<td align=center width=34 valign=middle> <img src='pic/gb.gif' border=0 alt=本分论坛的公告!不可不看!! width=20 height=17>
</td>
<td valign=middle align=left>
<%
try{
Vector forumNewsVector = ForumNewsManager.getForumNewsVector(forumID);
out.println("<marquee width=400 onmouseover=this.stop() onmouseout=this.start()>");
for(int f=0; f<forumNewsVector.size(); f++){
ForumNews forumNews = (ForumNews)forumNewsVector.get(f);
out.println("("+(f+1)+")<b><a href=announcements.jsp?forumID="+forumNews.getBoardid()+" target=_blank alt='"+forumNews.getTitle()+"'>"+forumNews.getTitle()+"</a></b> ("+forumNews.getAddTime()+") " );
}
out.println("</marquee>");
}
catch(ForumNewsNotFoundException e){
out.println("<b><a href=announcements.jsp?forumID=0 target=_blank alt='当前没有公告'>当前没有公告</a></b>("+NDate+")");
}
%>
</td>
<td align=right valign=middle><p>
<%=boardList%>
</p></td></tr></TBODY></TABLE>
<table cellspacing=0 border=0 width=<%=tableWidth%> bgcolor="<%=tableBackColor%>" align=center>
<tr><td height=1></td></tr></table>
<TABLE border=1 cellpadding=0 cellspacing=0 width=<%=tableWidth%> align=center bordercolor=<%=tableBackColor%>>
<TBODY><TR>
<TD height=27 width="<%=tableWidth%>" bgColor=<%=tableTitleColor%>><font color=<%=tableFontColor%>>目前论坛总在线<b><%=ForumFactory.getOLUsersNum()%></b>人,其中<%=theForum.getForumType()%>上共有 <b><%=theForum.getForumOLMemberUsersNum()%></b> 位会员与 <b><%=theForum.getForumOLGuestUsersNum()%></b> 位客人.今日贴子 <font color="<%=alertFontColor%>"><b><%=theForum.getTodayNum()%></b></font>
<%
out.println( " [<a href=online.jsp?forumID="+forumID+"><font color="+tableFontColor+">在线用户</font></a>]</TD><TD bgColor="+tableTitleColor+" width=\"5%\" align=center><a href='list.jsp?forumID="+ forumID+"&Page=1&skin="+ParamUtil.getString(request,"skin","")+"'>"+
"<img src='pic/refresh_1.gif' border=0 alt='刷新'></a></TD></TR>");
out.println( "</TBODY></TABLE>");
out.println(brTable);
out.println( "<table cellpadding=0 cellspacing=0 border=0 width=" + tableWidth + " align=center><tr>"+
"<td align=center width=2 valign=middle> </td>"+
"<td align=left valign=middle> <a href='announce.jsp?forumID="+ forumID +"'>"+
"<img src='pic/post.gif' border=0 alt='发新帖'></a>"+
" <a href='vote.jsp?forumID="+forumID+"'>"+
"<img src='pic/newpoll.gif' border=0 alt='发起新投票'></a></td>"+
"<td align=right> ");
if ((forumMaster&&theForum.getForumMaster().indexOf(userName)>-1)||master){
out.println( " <b><a href='admin_boardaset.jsp?forumID="+ forumID +"'>版务管理</a>");
}
out.println( "<b><a href='list.jsp?forumID="+forumID +"'>论坛帖子列表</a></b> <img src=pic/msn.gif width=20 height=20 alt=论坛版主列表> <select name=bz onchange=\"if(this.options[this.selectedIndex].value!='') openScript('dispuser.jsp?name='+this.options[this.selectedIndex].value,350,300)\"><option vaule=''>论坛版主</option>");
String masterName=theForum.getForumMaster();
if(masterName==null||"".equals(masterName)){
out.println("<option>暂缺</option>");
}else{
String [] masterNames=theForum.getForumMaster().split("\\|");
masterName="";
for(int k=0;k<masterNames.length;k++)
{
masterName=masterName+"<option value="+masterNames[k]+">"+masterNames[k]+"</option><br>" ;
}
out.println(masterName);
}
out.println("</select></td></tr></table>");
try{
Vector forumTopics=theForum.getForumBestTopics(forumID,Page,perPage);
%>
<table cellspacing=0 border=0 width=<%=tableWidth%> bgcolor="<%=tableBackColor%>" align=center><tr><td height=1></td></tr></table>
<TABLE border=1 cellPadding=0 cellSpacing=0 width=<%=tableWidth%> align=center bordercolor="<%=tableBackColor%>">
<TBODY>
<TR align=middle>
<TD height=27 width=32 bgColor="<%=tableTitleColor%>"><font color="<%=tableFontColor%>">状态</TD>
<TD bgColor="<%=tableTitleColor%>" width=*><font color="<%=tableFontColor%>">主 题 (点<img src=pic/plus.gif>即可展开贴子列表)</TD>
<TD bgColor="<%=tableTitleColor%>" width=80><font color="<%=tableFontColor%>">作 者</TD>
<TD bgColor="<%=tableTitleColor%>" width=64><font color="<%=tableFontColor%>">回复/人气</TD>
<TD bgColor="<%=tableTitleColor%>" width=195><font color="<%=tableFontColor%>">最后更新 | 回复人</TD>
</TR>
</TBODY></TABLE>
<%
for( i=0;i<forumTopics.size();i++){
ForumTopic forumTopic=(ForumTopic)forumTopics.get(i);
%>
<TABLE style=color:"<%=tableContentColor%>" border=1 cellPadding=0 cellSpacing=0 width=<%=tableWidth%> align=center bordercolor="<%=tableBackColor%>">
<TBODY><TR align=middle>
<TD bgColor="<%=aTableBodyColor%>" width=32 height=27>
<%
if(!forumTopic.getLockTopic()&&!forumTopic.getIsTop()&&!forumTopic.getIsVote()&&!forumTopic.getIsBest()&&!(forumTopic.getChildNum()>10)&&!forumTopic.getIsAllTop()){
out.println( "<img src=\"pic/folder.gif\" alt=开放主题>");
}else if(forumTopic.getIsVote()){
out.println("<img src=\"pic/closedb.gif\" alt=投票贴子>");
}else if(forumTopic.getIsTop()){
out.println("<img src=\"pic/istop.gif\" alt=固顶主题>");
}else if(forumTopic.getIsAllTop()){
out.println("<img src=\"pic/isalltop.gif\" alt=总固顶主题>");
}else if(forumTopic.getIsBest()){
out.println("<img src=\"pic/isbest.gif\" alt=精华帖子>");
}else if(forumTopic.getChildNum()>10){
out.println("<img src=\"pic/hotfolder.gif\" alt=热门主题>");
}else if(forumTopic.getLockTopic()){
out.println("<img src=\"pic/lockfolder.gif\" alt=本主题已锁定>");
}else{
out.println("<img src=\"pic/folder.gif\" alt=开放主题>");
}
%>
</TD>
<TD align=left bgcolor="<%=tableBodyColor%>" width=* onmouseover=javascript:this.bgColor='<%=aTableBodyColor%>' onmouseout=javascript:this.bgColor='<%=tableBodyColor%>'>
<%
if (forumTopic.getChildNum()==0){
out.println("<img src='"+picURL +"nofollow.gif' id='followImg"+forumTopic.getRootID()+"'>");
}else{
out.println("<img loaded=no src='"+picURL +"plus.gif' id='followImg"+forumTopic.getRootID()+"' style='cursor:hand;' onclick='loadThreadFollow("+forumTopic.getRootID()+","+forumTopic.getAnnounceID()+","+forumID+")' alt=展开贴子列表>");
}
if (forumTopic.getExpression()!=null&&!"".equals(forumTopic.getExpression())){
out.println("<a href=\"dispbbs.jsp?forumID="+forumID+"&rootID="+forumTopic.getRootID()+"&announceID="+forumTopic.getAnnounceID()+"&LPage="+Page+"\" target=_blank><img src='" + faceURL +forumTopic.getExpression()+"' border=0 alt=打开新窗口浏览此主题></a>");
}
out.println("<a href=\"dispbbs.jsp?forumID="+forumID+"&rootID="+forumTopic.getRootID()+"&announceID="+forumTopic.getAnnounceID()+"\" alt=\"《"+ forumTopic.getNoFilterTopic()+"》<br>作者:"+forumTopic.getUserName()+"<br>发表于"+forumTopic.getDateAndTime()+"<br>最后跟贴:"+response.encodeURL(forumTopic.getFollowMSG())+"...\">");
out.println(forumTopic.getNoFilterTopic());
out.println("</a>");
if(forumTopic.getIsBest()){
out.println("<img src=pic/marrow.gif>");
}
if(DateUtil.compareTo(DateUtil.calDate(-1) + " 23:59:59", forumTopic.getDateAndTime())){
out.print("<img src=\"pic/new.gif\" alt=新发主题>");
}
//
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -