⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 conferenceresult.jsp

📁 该源码包括了基于J2EE的数据持久层设计,设计中使用了DAO,Service,等模式,并在Struts下进行了测试.
💻 JSP
字号:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<%@ page language="java" contentType="text/html; charset=gb2312"%>
<%@ taglib uri="/WEB-INF/struts-bean.tld" prefix="bean" %>
<%@ taglib uri="/WEB-INF/struts-html.tld" prefix="html" %>
<%@ taglib uri="/WEB-INF/struts-logic.tld" prefix="logic" %>
<%@ page import="java.util.*"%>
<%@ page import="org.conference.pagination.RefreshablePagedListHolder"%>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title>ConferenceList</title>
<style type="text/css">
<!--
.style1 {
	font-size: 18;
	color: #FFFFFF;
}
.style3 {color: #FFFFFF}
.style4 {
	font-size: 18px;
	font-family: "Times New Roman", Times, serif;
}
a:link {
	text-decoration: none;
}
a:visited {
	text-decoration: none;
}
a:hover {
	text-decoration: underline;
}
a:active {
	text-decoration: none;
}
.style5 {
	font-size: 24px;
	font-weight: bold;
}
-->
</style>
</head>

<body>
<%
  RefreshablePagedListHolder holder =
  (RefreshablePagedListHolder) session.getAttribute("mySessionAttr");
   List conferenceList = holder.getPageList();
  int bcount = holder.getNrOfElements(); //获取blist大小
  int pgsize = holder.getPageSize();
  int pgcount = holder.getPageCount();
  int currentpgindex = holder.getPage();
  int firstlinkedpage = holder.getFirstLinkedPage();
  int lastlinkedpage = holder.getLastLinkedPage(); 
  int infNo=holder.getNrOfElements(); 
%>
<p class="style4">Your Location:<a href="<%=request.getContextPath()%>/pages/mainmenu.jsp"> Systemmenu</a>&gt;&gt;<a href="<%=request.getContextPath()%>/conferenceNews.do">Conference Query</a>&gt;&gt;Query Result </p>
<p align="center" class="style4 style5">Conference Query Results </p>
<table width="1000"  border="1" align="center" cellpadding="0" cellspacing="0" bordercolor="#CCCCCC" bordercolorlight="#000000">
  <tr bgcolor="#61B2DF">
    <th width="114" height="25" scope="col"><span class="style1">Title</span></th>
    <th width="83" height="25" scope="col"><span class="style3">Date</span></th>
    <th width="151" height="25" bgcolor="#61B2DF" scope="col"><span class="style3">Address</span></th>
    <th width="229" height="25" scope="col"><span class="style3">Url</span></th>
    <th width="83" height="25" scope="col"><span class="style3">Organizer</span></th>
    <th width="161" height="25" scope="col"><span class="style3">Interests</span></th>
    <th width="163" height="25" scope="col"><span class="style3">Comments</span></th>
  </tr>
 <logic:present name="conferenceList">
 <logic:iterate id="conferencevo" name="conferenceList"> 
  <tr>
    <td>&nbsp;<bean:write name="conferencevo" property="title"/></td>
    <td>&nbsp;<bean:write name="conferencevo" property="sdateforconference"/></td>
    <td>&nbsp;<bean:write name="conferencevo" property="address"/></td>
    <td>&nbsp;<bean:write name="conferencevo" property="url"/></td>
    <td>&nbsp;<bean:write name="conferencevo" property="organizer"/></td>
    <td>&nbsp;<bean:write name="conferencevo" property="interests"/></td>
    <td height="30">&nbsp;<bean:write name="conferencevo" property="comments"/></td>
  </tr>
  </logic:iterate>
  </logic:present>
  <tr>
    <td height="30" colspan="7">&nbsp;共<%=pgcount%>页&nbsp;&nbsp;共<%=infNo%>条&nbsp;
    <A HREF="conferenceQuery.do?operation=first">
        <b>首页</b>
   </A>    
     <%if (!holder.isFirstPage()) {    %>
      <A HREF="conferenceQuery.do?operation=pre">
        <b>上一页</b>
      </A>
    <%} else {    %>
      <b>上一页</b>
    <%}    %>
    <%
      for (int i = firstlinkedpage; i <= lastlinkedpage; i++) {
        if (i == currentpgindex) {
    %>
      <font color=red><%=i+1%>      </font>
    <%} else {    %>
      <A HREF="conferenceQuery.do?pgindex=<%=i%>"><%=i+1%>      </A>
    <%
      }
          }
    %>
    <%if (!holder.isLastPage()) {    %>
      <A HREF="conferenceQuery.do?operation=next">      
        <b>下一页</b>
      </A>
    <%} else {    %>
      <b>下一页</b>
    <%}    %>
    <A HREF="conferenceQuery.do?operation=last">
        <b>末页</b></td>
  </tr>
  
</table>
</body>
</html>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -