📄 list.jsp
字号:
<%@ page contentType="text/html;charset=euc-kr" import="java.net.*, board.BoardBean, board.BoardManager, CharacterSet"%><html><head><title>霸矫拱 格废</title><meta http-equiv="Content-Type" content="text/html; charset=euc-kr"><style type="text/css"><!-- .table {font-size:9pt; font-family : 蹈框 ;font-weight:bold;color:white;background:#6699CC; }a {text-decoration: none; } td { font-size : 10pt ; font-family : 蹈框 ; font-decoration : none ;} font { font-size : 10pt ; font-family : 蹈框 ; font-decoration : none ; } #title{ font-size : 10pt ; font-family : 蹈框 ; font-decoration : none ; font-weight : bold ; color : ffffff ;} .dform { font-family: 蹈框 ; font-size:10pt;color:white;background:#6699CC;} .ldTable { border-bottom:#636363 solid 1px;border-color:white; padding-top:5px; padding-bottom:5px; padding-left:3px; padding-right:3px; font-size:9pt}--></style><SCRIPT LANGUAGE="JavaScript">function CheckValues() { if(document.form1.query.value=="") { alert("八祸且 郴侩阑 涝仿窍技夸."); return; } else { document.form1.submit(); }}function open_window(name, url, left, top, width, height, toolbar, menubar, statusbar, scrollbar, resizable){ toolbar_str = toolbar ? 'yes' : 'no'; menubar_str = menubar ? 'yes' : 'no'; statusbar_str = statusbar ? 'yes' : 'no'; scrollbar_str = scrollbar ? 'yes' : 'no'; resizable_str = resizable ? 'yes' : 'no'; window.open(url, name, 'left='+left+',top='+top+',width='+width+',height='+height+',toolbar='+toolbar_str+',menubar='+menubar_str+',status='+statusbar_str+',scrollbars='+scrollbar_str+',resizable='+resizable_str);}</SCRIPT></head><% String pageString; int pg; // 翠函 霸矫拱狼 甸咯静扁甫 困茄 函荐 int wid = 0; int level = 0; try { // 其捞瘤 逞滚 pageString = request.getParameter("page"); pg = Integer.parseInt(pageString); } catch(Exception e) { pg = 1; } // 八祸绢 String find = request.getParameter("find"); String query = CharacterSet.toKorean(request.getParameter("query")); if(find == null) find = ""; if(query == null) query = ""; String tempQuery; try { BoardManager bm = new BoardManager(); BoardBean[] boardBean = bm.getList(pg, find, query); int totalPage = bm.getTotalPage(find, query); // 醚 其捞瘤 荐 int totalArticle = bm.getTotalArticle(find, query); // 醚 霸矫拱 荐 int todayArticle = bm.getTodayArticle(find, query); // 坷疵 霸矫拱 荐 int startPage = 1; // 茄 拳搁俊 割 其捞瘤鳖瘤 傅农甫 免仿且 巴牢啊 int pagePerScreen = 5; // 其捞瘤 傅农狼 矫累其捞瘤 拌魂 if((pg % pagePerScreen) == 0) startPage = (pg - pagePerScreen) + 1; else startPage = ((pg - 1) / pagePerScreen) * pagePerScreen + 1;%><body bgcolor="#FFFFFF" ><table align="center" width="602" border="0" cellspacing="0" cellpadding="0"> <tr> <td> <div align="left"><a href="JavaScript:open_window('admin', 'admin.jsp', 0, 0, 320, 160, 0, 0, 0, 0, 0);"><img src="images/admin.gif" width="55" height="29" border="0"></a></div> </td> <td> <div align="right"><font face="蹈框" size="2">坷疵 <%= todayArticle %>扒 / 醚 <%= totalArticle %>扒</font></div> </td> </tr></table><table width="602" border="0" cellspacing="0" cellpadding="0" align="center"> <tr> <td> <table border="0" cellpadding="0" cellspacing="0"> <tr> <td><img height="25" src="images/board01.gif" width="179"></td> <td><img height="25" src="images/board02.gif" width="352"></td> <td><img height="25" src="images/board-l.gif" width="71"></td> </tr> </table> <table bgcolor="#68b0d0" border="1" cellpadding="0" cellspacing="1" width="602"> <tr> <td width="600"> <table bgcolor="#ffffff" border="0" cellpadding="2" cellspacing="2" width="100%"> <tbody> <tr bgcolor="#ddf3fb"> <td width="10%"> <center><font face="蹈框" size="2">锅龋</font></center> </td> <td width="44%"> <center><font face="蹈框" size="2">力格</font></center> </td> <td width="6%"> <center><font face="蹈框" size="2">颇老</font></center> </td> <td width="15%"> <center><font face="蹈框" size="2">棵赴捞</font></center> </td> <td width="15%"> <center><font face="蹈框" size="2">朝楼</font></center> </td> <td width="10%"> <center><font face="蹈框" size="2">炼雀</font></center> </td> </tr><% if(boardBean[0].getTitle() != null) { for(int i = 0; i < boardBean.length; i++) { level = boardBean[i].getRe_level();%> <tr bgcolor="<%= (i % 2 == 0) ? "#f8f1da" : "#f6f6f6" %>" onmouseover="style.background='#DBDEEE'" onmouseout="style.background='<%= (i % 2 == 0) ? "#f8f1da" : "#f6f6f6" %>'"> <td height="20"> <center> <font size="2" face="蹈框" color="#000000"><%= boardBean[i].getIdx() %></font></center> </td> <td height="20"><% if(level > 0) { // 翠函 霸矫拱老 版快 wid = 10 * level; // 甸咯静扁 器牢飘%> <img src="images/level.gif" width="<%= wid %>" height="15"> <img src="images/re.gif" width="26" height="15"><% }%> <font size="2" face="蹈框" color="#000000"> <a href="view.jsp?idx=<%= boardBean[i].getIdx() %>&page=<%= pg %>&find=<%= find %>&query=<% // 八祸绢啊 茄臂老 版快甫 措厚秦 牢内爹 tempQuery = new String(query.getBytes(), "euc-kr"); tempQuery = URLEncoder.encode(tempQuery); out.print(tempQuery);%>"><%= (boardBean[i].getTitle().length() > 20) ? boardBean[i].getTitle().substring(0,20) : boardBean[i].getTitle() %></a> </font> </td><% if(!boardBean[i].getFilename().equals("")) { // 诀肺靛等 颇老捞 乐阑 版快%> <td height="20"> <center><font size="2" face="蹈框" color="#000000"><img src="images/file.gif" width="15" height="15"></a></font></center> </td><% } else {%> <td height="20"> <center><font size="2" face="蹈框" color="#000000"> </font></center> </td><% }%> <td height="20"> <center><font size="2" face="蹈框" color="#000000"><a href="mailto:<%= boardBean[i].getEmail() %>"><%= boardBean[i].getName() %></a></font></center> </td> <td height="20"> <center><font size="2" face="蹈框" color="#000000"><%= boardBean[i].getMoment().substring(0,10) %></font></center> </td> <td height="20"> <center><font size="2" face="蹈框" color="#000000"><%= boardBean[i].getCount() %></font></center> </td> </tr><% } }%> </table> </td> </tr> </table> </td> </tr> </table><table width="384" border="0" cellspacing="0" cellpadding="0" align="center"> <tr> <td height="38"> <table width="602" border="0" align="center" height="38"> <tr> <td> <div align="center"> <a href="list.jsp?page=<%= ((pg - 1) == 0 ? 1 : pg - 1) %>&find=<%= find %>&query=<% tempQuery = new String(query.getBytes(), "euc-kr"); tempQuery = URLEncoder.encode(tempQuery); out.print(tempQuery);%>"><img src="images/prev.gif" width="32" height="38" border="0"></a> <a href="write.jsp"><img src="images/accept.gif" width="32" height="38" border="0"></a> <a href="list.jsp?page=<%= ((pg + 1) <= totalPage ? pg + 1 : pg) %>&find=<%= find %>&query=<% tempQuery = new String(query.getBytes(), "euc-kr"); tempQuery = URLEncoder.encode(tempQuery); out.print(tempQuery);%>"><img src="images/next.gif" width="32" height="38" border="0"></a> </div> </td> </tr> </table> <table width="317" border="0" align="center" height="15"> <tr> <td> <div align="center"><% if(startPage != 1) { // 菊率狼 其捞瘤啊 乐促搁 << 肺 捞悼且 荐 乐档废 傅农 汲沥%> <a href="list.jsp?page=<%= startPage - 1 %>&find=<%= find %>&query=<% tempQuery = new String(query.getBytes(), "euc-kr"); tempQuery = URLEncoder.encode(tempQuery); out.print(tempQuery);%>"><<</a> <% } int k; for(k = startPage; (k <= startPage + pagePerScreen - 1) && k <= totalPage; k++) { if(k == pg) { // 泅犁 其捞瘤扼搁 其捞瘤 箭磊父 免仿%><%= k %> <% } else { // 傅农 汲沥%> <a href="list.jsp?page=<%= k %>&find=<%= find %>&query=<% tempQuery = new String(query.getBytes(), "euc-kr"); tempQuery = URLEncoder.encode(tempQuery); out.print(tempQuery);%>"><%= k %></a> <% } } if(k <= totalPage) { // 第俊 巢篮 其捞瘤啊 乐促搁 >> 肺 捞悼且 荐 乐档废 傅农 汲沥%> <a href="list.jsp?page=<%= k %>&find=<%= find %>&query=<% tempQuery = new String(query.getBytes(), "euc-kr"); tempQuery = URLEncoder.encode(tempQuery); out.print(tempQuery);%>">>></a><% }%> </div> </td> </tr> </table> </td> </tr> <tr> <td> <table align="center" width="395" border="0" cellspacing="0" cellpadding="0"> <tr valign="middle"> <td height="20" align="center"> <form name="form1" action="list.jsp" method="post" > <select name="find"> <option value="title">力格</option> <option value="content">郴侩</option> <option value="total">力格+郴侩</option> <option value="name">臂敬捞</option> </select> <input type="text" name="query" size="20"> <input type="button" name="Button" value="八祸" onClick="CheckValues()"> </form> </td> </tr> </table> </td> </tr></table><% } catch(Exception ex) { }%></body></html>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -