MyException - 我的异常网
当前位置:我的异常网» Java Web开发 » JSP条件查询翻页有关问题

JSP条件查询翻页有关问题(3)

www.MyException.Cn  网友分享于:2013-12-11  浏览:1651次

<!--
.STYLE1 {
font-size: 9pt;
font-weight: normal;
}
.STYLE6 {font-size: 9pt}
.www { font-family: "宋体 ";
font-size: 12px;
}
.STYLE7 { font-size: 14px;
font-weight: bold;
}
-->
</style>
</head>
<body style= "background-color: #cad7f7; ">
<table width= "80% " border= "0 " align= "center " cellpadding= "3 " cellspacing= "1 " class= "STYLE1 ">
<!--DWLayoutTable-->
<tr align= "center " >
<td height= "12 " colspan= "4 " background= "../images/admin_top_bg.gif "> <span class= "STYLE7 "> 后台管理------&gt; <%=ArticleConst.name%> 文章管理 </span> </td>
</tr>
<tr align= "center " >
<td height= "12 " colspan= "4 " align= "left " background= "../images/admin_top_bg.gif "> <select name= "type " id= "type " onChange= "go(this.options[this.selectedIndex].value) ">
<option value= "-1 "> 请选择要管理的栏目 </option>
<%

Map map = ArticleConst.getInstance().getMap();
Map mapID = ArticleConst.getInstance().getMapID();
Iterator it = map.keySet().iterator();
while(it.hasNext())
{
Object o = it.next();

%>
<option value= " <%=o%> "> <%=map.get(o)%> </option>
<%
}
%>
</select> </td>
</tr>
<tr bgcolor= "#f1f3f5 ">
<td width= "440 " height= "22 " align= "center "> 文章标题 </td>
<td width= "165 " align= "center "> 发布日期 </td>
<td width= "50 " align= "center "> 点击数 </td>
<td width= "112 " rowspan= "2 " align= "center "> 操作 </td>
</tr>

<tr bgcolor= "#f1f3f5 ">
<td> </td>
<td> </td>
<td> </td>
</tr>
<%
while(rs.next())
{

%>
<tr bgcolor= "#f1f3f5 ">
<td height= "25 "> [ <a href= ' <%=thisPageName+ "?type= "+rs.getInt( "type ")%> '> <%=map.get(Integer.valueOf(rs.getInt( "type ")))%> </a> ] <%=rs.getString( "title ")%> </td>
<td> <%=rs.getString( "releaseDate ")%> </td>
<td> <%=rs.getInt( "click ")%> </td>
<td width= "112 " align= "center "> <a href= " <%=ArticleConst.path%> /nr.jsp?id= <%=rs.getInt( "id ")%> "> 查看 </a> | <a href= "modifyInfo.jsp?id= <%=rs.getInt( "id ")%> &action=del "> 修改 </a> | <a href= 'deleteInfo.jsp?id= <%=rs.getInt( "id ")%> '> 删除 </a> </td>

</tr>
<%
}
sessions.close();
%>
<tr bgcolor= "#f1f3f5 ">

<td height= "20 " colspan= "4 " align= "right " valign= "top "> <label> <span class= "www "> 共有 <%=p.getDataCount()%> 项查询结果&nbsp;目前显示&nbsp;第 <%=(p.getCurrentPage()==1)?1:(p.getDisCount())*(p.getCurrentPage())-p.getDisCount()%> - <%=(p.getDisCount())*(p.getCurrentPage())%> 项&nbsp; <a href= ' <%=disPageName%> page=1 '> 首页 </a> &nbsp; <a href= ' <%=disPageName%> page= <%=(p.getCurrentPage())-1%> '> 上一页 </a> &nbsp; <a href= ' <%=disPageName%> page= <%=(p.getCurrentPage())+1%> '> 下一页 </a> &nbsp; <a href= ' <%=disPageName%> page= <%=p.getPageCount()%> '> 末页 </a> </span> </label> </td>

文章评论

软件开发程序错误异常ExceptionCopyright © 2009-2015 MyException 版权所有