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

📄 bookmain.jsp

📁 用STRUTS ,HIBERNATE, SPRING 三种框架整合做的实战项目
💻 JSP
字号:
<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%@taglib uri="/WEB-INF/struts-html.tld" prefix="html"%>
<%@taglib uri="/WEB-INF/struts-bean.tld" prefix="bean"%>
<%@taglib uri="/WEB-INF/struts-logic.tld" prefix="logic"%>
<%
String path = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
%>

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
  <head>
    <base href="<%=basePath%>">
    
    <title>My JSP 'bookmain.jsp' starting page</title>
    
	<meta http-equiv="pragma" content="no-cache">
	<meta http-equiv="cache-control" content="no-cache">
	<meta http-equiv="expires" content="0">    
	<meta http-equiv="keywords" content="keyword1,keyword2,keyword3">
	<meta http-equiv="description" content="This is my page">
	<!--
	<link rel="stylesheet" type="text/css" href="styles.css">
	-->

  </head>
  
  <body> 
  <table width="868" border="1" align="center" height="465">
<tbody><tr>
<td><html:form method="POST" action="/search.do">
<br>

<input type="text" name="searchText"> 
<select size="1" name="searchList">
<option value="name">书名</option>
<option value="author">作者</option>
</select>
<input type="submit" value="提交" name="submit"><br><br><br>
</html:form></td></tr>
<tr><td><bean:message key="downloadCenter"/></td></tr>
<tr>
<td>书籍信息总目录:<br>一共查询到<bean:write name="page" property="totalRows"/>条记录,
显示<bean:write name="page" property="currentPage"/>页
/共<bean:write name="page" property="totalPages"/>页</td>
</tr>
<tr>
<td></td>
</tr>
<tr>
<td>
<table width="500" border="1" align="center"><tbody>
<tr>
<td><bean:message key="bookName"/></td>
<td><bean:message key="bookPrice"/></td>
<td><bean:message key="bookNumber"/></td>
<td><bean:message key="editor"/></td>
<td><bean:message key="description"/></td>
</tr>
<bean:define id="Book" name="book" scope="session"/>
<logic:iterate id="BookList" name="Book">
<tr>
<td><bean:write name="BookList" property="name"/></td>
<td><bean:write name="BookList" property="price"/></td>
<td><bean:write name="BookList" property="number"/></td>
<td><bean:write name="BookList" property="author"/></td>
<td><html:link page="/bookdetail.do" paramId="bookId"
paramName="BookList" paramProperty="id"><html:img src="images/view.gif"/></html:link></td>
</tr>
</logic:iterate>
</tbody></table>
</td></tr>
<tr><td>
<bean:define id="Category" name="category" scope="session" />
<html:link page="/booklist.do?action=first" paramId="cateId"
paramName="page" paramProperty="categoryId">首页|</html:link>

<logic:equal name="page" property="hasPrevious" value="true">
<html:link page="/booklist.do?action=previous" paramId="cateId"
paramName="page" paramProperty="categoryId">上页|</html:link>
</logic:equal>
<logic:equal name="page" property="hasPrevious" value="false">
上页|
</logic:equal>

<logic:equal name="page" property="hasNext" value="true">
<html:link page="/booklist.do?action=next" paramId="cateId"
paramName="page" paramProperty="categoryId">下页|</html:link>
</logic:equal>
<logic:equal name="page" property="hasNext" value="false">
下页|
</logic:equal>

<html:link page="/booklist.do?action=last" paramId="cateId"
paramName="page" paramProperty="categoryId">末页</html:link>
</td></tr>
</tbody></table> 
  </body>
</html>

⌨️ 快捷键说明

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