📄 listtopic.jsp
字号:
</a></td>
<td onMouseOver="this.style.backgroundColor='#ffffff'"
onMouseOut="this.style.backgroundColor=''" align=left bgcolor=#f8f8f8><%
if (recount==0) {
%>
<img id=followImg<%=id%> title="<lt:Label res="res.label.forum.listtopic" key="extend_reply"/>" src="<%=skinPath%>/images/minus.gif" loaded="no">
<% }else { %>
<img id=followImg<%=id%> title=<lt:Label res="res.label.forum.listtopic" key="extend_reply"/> style="CURSOR: hand"
onClick="loadThreadFollow(<%=id%>,<%=id%>,'&boardcode=<%=boardcode%>')" src="<%=skinPath%>/images/plus.gif" loaded="no">
<% } %>
<strong><lt:Label res="res.label.forum.listtopic" key="top"/></strong>
<%
String attIcon = MsgUtil.getIconImg(msgdb);
if (!attIcon.equals("")) {
out.print("<img src='../images/fileicon/" + attIcon + "'>");
}
%>
<a href="<%=ForumPage.getShowTopicPage(request, msgdb.getId())%>">
<%
String color = StrUtil.getNullString(msgdb.getColor());
String tp = topic;
if (!color.equals(""))
tp = "<font color='" + color + "'>" + tp + "</font>";
if (msgdb.isBold())
tp = "<B>" + tp + "</B>";
%>
<%=tp%> </a>
<%if (iselite==1) { %>
<IMG src="images/topicgood.gif">
<%}%>
<%
//计算共有多少页回贴
int allpages = Math.round((float)recount/10+0.5f);
if (allpages>1)
{
int pg = allpages;
if (allpages>10)
pg = 10;
out.print("[");
for (int m=1; m<=pg; m++)
{%>
<a href="<%=ForumPage.getShowTopicPage(request, msgdb.getId(), m)%>"><%=m%></a>
<%}
if (allpages>10) {%>
...<a href="<%=ForumPage.getShowTopicPage(request, msgdb.getId(), allpages)%>"><%=allpages%></a>
<%}
out.print("]");
}%></td>
<td class="list_td" align=middle width=91 bgcolor=#ffffff> <% if (privilege.getUser(request).equals(name)) { %> <IMG height=14 src="<%=skinPath%>/images/my.gif"
width=14> <% } %> <a href="../userinfo.jsp?username=<%=StrUtil.UrlEncode(name)%>"><%=ud.getNick()%></a> </td>
<td align=middle width=55 bgcolor=#f8f8f8><%=recount%></td>
<td align=middle width=55 bgcolor=#ffffff class="list_td"><%=hit%></td>
<td align=left width=80 bgcolor=#f8f8f8 class="list_date">
<%if (rename.equals("")) {%>
<%=lydate%>
<%}else{%>
<%=redate%>
|
<a href="../userinfo.jsp?username=<%=StrUtil.UrlEncode(rename,"utf-8")%>" title="<lt:Label res="res.label.forum.listtopic" key="topic_date"/><%=lydate%>"><%=reUserDb.getNick()%></a>
<%}%> </td>
</tr>
<tr id=follow<%=id%> style="DISPLAY: none">
<td noWrap align=middle width=30> </td>
<td align=middle width=17 class="list_td_emote"> </td>
<td align=left colspan="5">
<div id=followDIV<%=id%> style="WIDTH: 100%" onClick=loadThreadFollow(<%=id%>,<%=id%>,"&hit=<%=hit+1%>&boardname=<%=urlboardname%>")><lt:Label res="res.label.forum.listtopic" key="wait"/></div></td>
</tr>
</tbody>
</table>
<%}%>
<table bordercolor=<%=skin.getTableBorderClr()%> width="98%" border="1" align="center" cellpadding="1" cellspacing="0" class="list">
<tr>
<td width="30"> </td>
<td><strong> <lt:Label res="res.label.forum.listtopic" key="topic"/></strong></td>
</tr>
</table>
<%
while (irmsg.hasNext()) {
msgdb = (MsgDb) irmsg.next();
i++;
id = ""+msgdb.getId();
topic = StrUtil.toHtml(msgdb.getTitle());
name = msgdb.getName();
ud = um.getUser(name);
lydate = com.redmoon.forum.ForumSkin.formatDateTime(request, msgdb.getAddDate());
recount = msgdb.getRecount();
hit = msgdb.getHit();
expression = msgdb.getExpression();
type = msgdb.getType();
iselite = msgdb.getIsElite();
islocked = msgdb.getIsLocked();
level = msgdb.getLevel();
rename = msgdb.getRename();
if (!rename.equals(""))
reUserDb = um.getUser(rename);
redate = com.redmoon.forum.ForumSkin.formatDateTime(request, msgdb.getRedate());
%>
<table class="list" bordercolor="<%=skin.getTableBorderClr()%>" cellspacing=0 cellpadding=1 width="98%" align=center border=1>
<tbody>
<tr>
<td noWrap align=middle width=30 bgcolor=#f8f8f8>
<% if (level==MsgDb.LEVEL_TOP_BOARD) { %>
<IMG alt="" src="<%=skinPath%>/images/f_top.gif" border=0>
<% }
else {
if (recount>20){ %> <img alt="<lt:Label res="res.label.forum.listtopic" key="open_topic_hot"/>" src="<%=skinPath%>/images/f_hot.gif"> <%}
else if (recount>0) {%> <img alt="<lt:Label res="res.label.forum.listtopic" key="open_topic_reply"/>" src="<%=skinPath%>/images/f_new.gif"> <%}
else {%> <img alt="<lt:Label res="res.label.forum.listtopic" key="open_topic_no_reply"/>" src="<%=skinPath%>/images/f_norm.gif"> <%}
}%>
</td>
<td class="list_td_emote" align=middle width=17 bgcolor=#ffffff> <% String urlboardname = StrUtil.UrlEncode(boardname,"utf-8"); %> <a href="<%=ForumPage.getShowTopicPage(request, msgdb.getId())%>" target=_blank>
<%
if (islocked==1) { %>
<IMG height=15 alt="" src="<%=skinPath%>/images/f_locked.gif" width=17 border=0>
<% }
else {
if (type==1) { %>
<IMG height=15 alt="" src="<%=skinPath%>/images/f_poll.gif" width=17 border=0>
<%}else { %>
<img src="images/brow/<%=expression%>.gif" border=0>
<%}
} %>
</a></td>
<td onMouseOver="this.style.backgroundColor='#ffffff'"
onMouseOut="this.style.backgroundColor=''" align=left bgcolor=#f8f8f8> <%
if (recount==0) {
%>
<img id=followImg<%=id%> title=<lt:Label res="res.label.forum.listtopic" key="no_reply"/> src="<%=skinPath%>/images/minus.gif" loaded="no">
<% }else { %>
<img id=followImg<%=id%> title=<lt:Label res="res.label.forum.listtopic" key="extend_reply"/> style="CURSOR: hand"
onClick="loadThreadFollow(<%=id%>,<%=id%>,'&boardcode=<%=boardcode%>')" src="<%=skinPath%>/images/plus.gif" loaded="no">
<%}%>
<%
String attIcon = MsgUtil.getIconImg(msgdb);
if (!attIcon.equals("")) {
out.print("<img src='../images/fileicon/" + attIcon + "'>");
}
%>
<%
// plugin
if (!msgdb.getPluginCode().equals("")) {
PluginUnit pu = pm.getPluginUnit(msgdb.getPluginCode());
out.print(pu.getName(request) + " ");
}
// 子类别
if (ttv.size()>0) {
if (msgdb.getThreadType()!=ThreadTypeDb.THREAD_TYPE_NONE) {
ttd = ttm.getThreadTypeDb(msgdb.getThreadType());
out.print("<a href='" + ForumPage.getListTopicPage(request, boardcode, 0, 1, ttd.getId()) + "'>[" + ttd.getName() + "]</a>");
}
}
%>
<a href="<%=ForumPage.getShowTopicPage(request, msgdb.getId())%>">
<%
String color = StrUtil.getNullString(msgdb.getColor());
String tp = topic;
if (!color.equals(""))
tp = "<font color='" + color + "'>" + tp + "</font>";
if (msgdb.isBold())
tp = "<B>" + tp + "</B>";
%>
<%=tp%>
</a>
<%if (iselite==1) { %>
<IMG src="images/topicgood.gif">
<%}%>
<%
// 计算共有多少页回贴
int allpages = Math.round((float)recount/10+0.5f);
if (allpages>1) {
int pg = allpages;
if (allpages>10)
pg = 10;
out.print("[");
for (int m=1; m<=pg; m++)
{%>
<a href="<%=ForumPage.getShowTopicPage(request, msgdb.getId(), m)%>"><%=m%></a>
<%}
if (allpages>10) {%>
...<a href="<%=ForumPage.getShowTopicPage(request, msgdb.getId(), allpages)%>"><%=allpages%></a>
<%}
out.print("]");
}%>
</td>
<td class="list_td" align=middle width=91 bgcolor=#ffffff> <% if (privilege.getUser(request).equals(name)) { %> <IMG height=14 src="<%=skinPath%>/images/my.gif"
width=14> <% } %> <a href="../userinfo.jsp?username=<%=StrUtil.UrlEncode(name)%>"><%=ud.getNick()%></a> </td>
<td align=middle width=55 bgcolor=#f8f8f8><%=recount%></td>
<td align=middle width=55 bgcolor=#ffffff class="list_td"><%=hit%></td>
<td align=left width=80 bgcolor=#f8f8f8 class="list_date">
<%if (rename==null || rename.equals("")) {
if (lydate!=null) {
%>
<%=lydate%>
<%}
}else{%>
<%=redate%>
|
<a href="../userinfo.jsp?username=<%=StrUtil.UrlEncode(rename,"utf-8")%>" title="<lt:Label res="res.label.forum.listtopic" key="topic_date"/><%=lydate%>"><%=reUserDb.getNick()%></a>
<%}%></td>
</tr>
<tr id=follow<%=id%> style="DISPLAY: none">
<td noWrap align=middle width=30> </td>
<td align=middle width=17 class="list_td_emote"> </td>
<td onMouseOver="this.style.backgroundColor='#ffffff'"
onMouseOut="this.style.backgroundColor=''" align=left colspan="5">
<div id=followDIV<%=id%> style="WIDTH: 100%;"
onClick=loadThreadFollow(<%=id%>,<%=id%>,"&hit=<%=hit+1%>&boardname=<%=urlboardname%>")><lt:Label res="res.label.forum.listtopic" key="wait"/></div></td>
</tr>
</tbody>
</table>
<%}%>
<table width="98%" border="0" cellspacing="1" cellpadding="3" align="center" class="9black">
<tr>
<td width="11%" align="right"><select name="selboard" onChange="if(this.options[this.selectedIndex].value!=''){location='listtopic.jsp?' + this.options[this.selectedIndex].value;}">
<option value="" selected><lt:Label res="res.label.forum.listtopic" key="sel_board"/></option>
<%
LeafChildrenCacheMgr dlcm = new LeafChildrenCacheMgr("root");
java.util.Vector vt = dlcm.getChildren();
Iterator ir = vt.iterator();
while (ir.hasNext()) {
Leaf leaf = (Leaf) ir.next();
String parentCode = leaf.getCode();
if (leaf.getIsHome()) {
%>
<option style="BACKGROUND-COLOR: #f8f8f8" value="">╋ <%=leaf.getName()%></option>
<%
LeafChildrenCacheMgr dl = new LeafChildrenCacheMgr(parentCode);
java.util.Vector v = dl.getChildren();
Iterator ir1 = v.iterator();
while (ir1.hasNext()) {
Leaf lf = (Leaf) ir1.next();
String selected = boardcode.equals(lf.getCode())?"selected":"";
%>
<option value="boardcode=<%=StrUtil.UrlEncode(lf.getCode(),"utf-8")%>&boardname=<%=StrUtil.UrlEncode(lf.getName(),"utf-8")%>" <%=selected%>> ├『<%=lf.getName()%>』</option>
<%}
}
}%>
</select></td>
<td width="60" height="23" align="left">
<%if (privilege.isManager(request, boardcode)) {%>
<a href="manager/boardRule.jsp?boardcode=<%=StrUtil.UrlEncode(boardcode)%>"><lt:Label res="res.label.forum.listtopic" key="manage_board"/></a>
<%}%> </td>
<td width="74%" align="right"><%
String querystr = "boardcode=" + boardcode + "&op=" + op + "&threadType=" + threadType;
if (op.equals(""))
out.print(paginator.getListTopicCurPageBlock(request, boardcode, 0, threadType));
else
out.print(paginator.getCurPageBlock(request, "listtopic.jsp?"+querystr));
%></td>
</tr>
</table>
<TABLE borderColor=#cccccc cellSpacing=0 cellPadding=4 width="98%" align=center
border=1>
<TBODY>
<TR>
<TD height="26" background="<%=skinPath%>/images/bg1.gif" class="online">
<span>
<%
OnlineInfo oli = new OnlineInfo();
int boardcount = oli.getBoardCount(boardcode);
int boardusercount = oli.getBoardUserCount(boardcode);
int boardguestcount = boardcount - boardusercount;
%>
<lt:Label res="res.label.forum.listtopic" key="online"/> <%=oli.getAllCount()%> <lt:Label res="res.label.forum.listtopic" key="ren"/> <lt:Label res="res.label.forum.listtopic" key="cur_board"/> <%=boardcount%> <lt:Label res="res.label.forum.listtopic" key="ren"/> <lt:Label res="res.label.forum.listtopic" key="regist_user"/> <%=boardusercount%> <lt:Label res="res.label.forum.listtopic" key="ren"/>
<lt:Label res="res.label.forum.listtopic" key="guest"/> <%=boardguestcount%> <lt:Label res="res.label.forum.listtopic" key="ren"/> <lt:Label res="res.label.forum.listtopic" key="today_post"/> <%=curleaf.getTodayCount()%>
</span> <A title="<lt:Label res="res.label.forum.listtopic" key="show_online"/>" href="javascript:loadonline('<%=boardcode%>')"><IMG id=followImg000 style="CURSOR: hand"
src="images/plus.gif" border=0 loaded="no">
<SPAN id=advance><lt:Label res="res.label.forum.listtopic" key="show_online"/></SPAN></A></TD>
</TR>
<TR>
<TD
style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; PADDING-BOTTOM: 0px; PADDING-TOP: 0px"
colSpan=4><DIV id="followDIV000" name="followDIV000">
<div style="display:none; BORDER-RIGHT: black 1px solid; PADDING-RIGHT: 2px; BORDER-TOP: black 1px solid; PADDING-LEFT: 2px; PADDING-BOTTOM: 2px; MARGIN-LEFT: 18px; BORDER-LEFT: black 1px solid; WIDTH: 240px; COLOR: black; PADDING-TOP: 2px; BORDER-BOTTOM: black 1px solid; BACKGROUND-COLOR: lightyellow"
onclick="loadonline('<%=boardcode%>')"><lt:Label res="res.label.forum.listtopic" key="wait_online"/></DIV>
</div></TD>
</TR>
</TBODY>
</TABLE>
<TABLE width="98%" border=0 align="center" cellPadding=0 cellSpacing=0>
<TBODY>
<TR>
<TD><TABLE width="100%" border=0 align="center"
cellPadding=0 cellSpacing=4 borderColor=#111111 style="BORDER-COLLAPSE: collapse">
<TBODY>
<TR>
<TD noWrap width=200><IMG height=12 alt=""
src="<%=skinPath%>/images/f_new.gif" width=18 border=0> <lt:Label res="res.label.forum.listtopic" key="topic_reply"/></TD>
<TD noWrap width=100><IMG height=12 alt=""
src="<%=skinPath%>/images/f_hot.gif" width=18 border=0> <lt:Label res="res.label.forum.listtopic" key="topic_hot"/> </TD>
<TD noWrap width=100><IMG height=15 alt=""
src="<%=skinPath%>/images/f_locked.gif" width=17 border=0> <lt:Label res="res.label.forum.listtopic" key="topic_lock"/></TD>
<TD noWrap width=150><IMG src="images/topicgood.gif"> <lt:Label res="res.label.forum.listtopic" key="topic_elite"/></TD>
<TD noWrap width=150><IMG height=15 alt="" src="images/top_forum.gif" width=15 border=0> <lt:Label res="res.label.forum.listtopic" key="topic_all_top"/></TD>
</TR>
<TR>
<TD noWrap width=200><IMG height=12 alt=""
src="<%=skinPath%>/images/f_norm.gif" width=18 border=0> <lt:Label res="res.label.forum.listtopic" key="topic_no_reply"/></TD>
<TD noWrap width=100><IMG height=15 alt=""
src="<%=skinPath%>/images/f_poll.gif" width=17 border=0> <lt:Label res="res.label.forum.listtopic" key="topic_vote"/></TD>
<TD noWrap width=100><IMG height=15 alt=""
src="<%=skinPath%>/images/f_top.gif" width=15 border=0> <lt:Label res="res.label.forum.listtopic" key="topic_top"/></TD>
<TD noWrap width=150><IMG height=14 src="<%=skinPath%>/images/my.gif"
width=14> <lt:Label res="res.label.forum.listtopic" key="topic_my"/></TD>
<TD noWrap width=150> </TD>
</TR>
</TBODY>
</TABLE></TD>
</TR></TBODY></TABLE>
<table width="98%" border="0" align="center" cellpadding="0" cellspacing="0">
<tr>
<td align="center">
<%
long pageEndTime = System.currentTimeMillis();
long t = pageEndTime - pageBeginTime;
%>
<lt:Label res="res.label.forum.listtopic" key="page_run"/><%=t%><lt:Label res="res.label.forum.listtopic" key="mili_second"/> </td>
</tr>
</table>
<jsp:include page="inc/footer.jsp" />
</BODY></HTML>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -