日期:2014-05-16  浏览次数:20388 次

jsp学习笔记(24)
bookDetail.jsp页面
	<%@ page language="java" contentType="text/html; charset=gb2312"
	pageEncoding="gb2312"%>
	<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" 	"http://www.w3.org/TR/html4/loose.dtd">
	<%@page import="java.util.ArrayList"%><html>
	<head>
	<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
	<title>网上书店</title>
	<link href="../css/style.css" rel="stylesheet" type="text/css" />
	<link type="text/css" rel="stylesheet" href="../jquery/jquery_dialog.css" />
	<script type="text/javascript" src="../jquery/jquery.js"></script>
	<script type="text/javascript" src="../jquery/jquery_dialog.js"></script>
	</head>
	<body>	
	<div id="container">
		<%@include file="header.jsp" %>
	<div id="header">
	<div id="special_offers"></div>
	<div id="new_books"></div>
	</div>
	<div id="content">
	<%@include file="left.jsp" %>
	<%  
		ArrayList al = (ArrayList)request.getAttribute("bookinf");
		ArrayList bookinf = (ArrayList)al.get(0); 
	%>
	<div id="content_right">
	<h1>图书详细信息</h1>
		<div class="image_panel"><img src="../<%=bookinf.get(11) %>"  alt="" width="100" 
		height="150" /></div>
		<ul>
		<li>书名:<%=bookinf.get(1) %></li>
		<li>作者:<%=bookinf.get(2) %></li>
        <li>出 版 社:<%=bookinf.get(3) %></li>
        <li>ISBN:<%=bookinf.get(4) %></li>
        <li>价格:<%=bookinf.get(5) %></li>
        <li>库存:<%=bookinf.get(6) %></li>
		</ul>
		<div class="buy_now_button"><a href="#"onclick="JqueryDialog.Open('购物车
		','/OnlineShop/servlet/ShoppingServlet?method=add&bookId=<%=
		bookinf.get(0)%>&bookName=<%=bookinf.get(1) %>&bookQuantity=
		1&bookPrice=<%=bookinf.get(5) %>', 630, 300);">购买</a></div>
		<p><%=bookinf.get(7)%></p>
		<div class="cleaner_with_height">&nbsp;</div>
		<a href="http://www.865171.cn/"><img src="../images/ads_cn.jpg" alt="css template 
		ad" /></a>
	 </div>
	<div class="cleaner_with_height">&nbsp;</div>
	</div>
	<div id="footer"> 
		Copyright &copy; 2010<strong>NIT</strong>| Designed by NIT </div>
	</div>
	</body>
	</html>