📄 zwbook.jsp
字号:
<%@ page contentType="text/html; charset=gb2312" language="java" import="java.sql.*" errorPage="" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
<title>无标题文档</title>
<style type="text/css">
<!--
BODY {
BACKGROUND-IMAGE: none; BACKGROUND-COLOR: #ade3ff
}
.STYLE5 {color: #FFFFFF; font-weight: bold; }
.STYLE6 { font-family: "楷体_GB2312";
color: #FF0000;
}
-->
</style>
<jsp:useBean id="ConnBean" scope="page" class="com.bean.db.conn" />
</head>
<body>
<h1 align="center"><span class="STYLE6">图书统计</span></h1>
<br />
<table width="96%" border="1" cellpadding="0" cellspacing="0" bordercolor="#999999">
<tr align="center">
<td width="11%" bgcolor="#000099"><span class="STYLE5">图书编号</span></td>
<td width="18%" bgcolor="#000099"><span class="STYLE5">书名</span></td>
<td width="31%" bgcolor="#000099"><span class="STYLE5">出版社</span></td>
<td width="10%" bgcolor="#000099"><span class="STYLE5">作者</span></td>
<td width="8%" bgcolor="#000099"><span class="STYLE5">定价</span></td>
<td width="22%" bgcolor="#000099"><span class="STYLE5">借阅人</span></td>
</tr>
<%
String sql="select * from book";
for(ResultSet rst = ConnBean.executeQuery(sql);rst.next();){
String ids=rst.getString("id");
int wsl=rst.getInt("iosl");
if (wsl>0){
sql="select top "+wsl+" * from jcqk where id="+ids;
for(ResultSet rs = ConnBean.executeQuery(sql);rs.next();){
%>
<tr>
<td> <%=rs.getString("bid")%></td>
<td> <%=rs.getString("bname")%></td>
<td> <%=rs.getString("bcbs")%></td>
<td> <%=rs.getString("bzz")%></td>
<td> <%=rs.getString("bdj")%></td>
<td nowrap="nowrap"> <%=rs.getString("Cid")%></td>
</tr>
<%
}}}
%>
</table>
</body>
</html>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -