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

📄 bloglist.jsp

📁 是用jsp开发搏客网站管理系统。 同时含有该系统所需的数据库。使用起来方便。
💻 JSP
字号:

<%@ page language="java" import="java.util.*,huc.blog.bean.*,huc.blog.util.*" pageEncoding="UTF-8"%>
<%@ page import="huc.blog.util.PageObject" %>
<%String path = request.getContextPath();
			String basePath = request.getScheme() + "://"
					+ request.getServerName() + ":" + request.getServerPort()
					+ path + "/";
%>

<%
	User loginUser = (User)ParamUtils.getObjectAttribute(session, "loginUser", null);
	PageObject pageObject = (PageObject)ParamUtils.getObjectAttribute(request, "page", null);
%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
	<head>
		<base href="<%=basePath%>">

		<title>博客-日志管理</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">
		<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
		
		<link rel="stylesheet" type="text/css" href="css/styles.css">
		<SCRIPT language="javascript" src="js/blog.js"></SCRIPT>

	</head>

	<body>
		<jsp:include page="common/header.jsp">
			<jsp:param name="userid" value="<%=loginUser.getId()%>"/>
			<jsp:param name="spaceName" value="<%=loginUser.getSpaceName()%>"/>
		</jsp:include>
<form action="servlet/ManageBlog?userid=<%=loginUser.getId()%>" method="post">
		  <input type="hidden" name="cmd">
		  <input type="hidden" name="id">
		  
  <table width="800" align="center">
    <tr>
	          <td height="19" align="left">日志列表</td>
	          <td width="5%" align="right"><INPUT type="button" class="inputbtn" name="turnoverButton" value="反选" onclick="turnover();"></td>
	          <td width="8%" align="right"><INPUT type="submit" class="inputbtn" name="addButton" value="发表文章" onclick="doSubmit('add')"></td>
	          <td width="8%" align="right"><INPUT type="submit" class="inputbtn" name="delButton" value="删除文章" onclick="return doDeleteSubmit();"></td>
	        </tr>
		  </table>
	      
  <table width="800"  border="1" align="center" cellspacing="0" bgcolor="#E4EDFB">
    <tr align="center">
	          <td width="5%" height="19">选择</td>
	          <td width="40%">日志标题</td>
	          <td width="13%">日志类型</td>
	          <td width="22%">创建日期</td>
	          <td width="20%">操作</td>
	        </tr>
	        <%
	        	int i = 0;
	        	for(;i < pageObject.getList().size(); i++){
	         			Blog blog = (Blog)pageObject.getList().get(i);
	        %>
	        <tr align="center">
	        	<td height="18"><INPUT type="checkbox" name="checkedIds" value="<%=blog.getId()%>"></td>
	          	<td><%=blog.getTitle()%></td>
	        	<td><%=blog.getCategory().getCategoryName()%></td>
	        	<td><%=blog.getPublishTime().substring(0,blog.getPublishTime().length()-2)%></td>
	        	<td>
	        		<INPUT type="submit" name="viewButton" value="查看" class="inputbtn" onclick="doSubmit('view','<%=blog.getId()%>')">&nbsp;
	        		<INPUT type="submit" name="editButton" value="修改" class="inputbtn" onclick="doSubmit('edit','<%=blog.getId()%>')">
	        	</td>
	        </tr>
	        <%
	        	}
	        	for(;i < pageObject.getPageSize(); i++){
	        %>
	        <tr align="center">
	          	<td>&nbsp;</td>
	          	<td>&nbsp;</td>
	        	<td>&nbsp;</td>
	        	<td>&nbsp;</td>
	        	<td>&nbsp;</td>
	        </tr>
	        <%
	        	}
	        %>
	      </table>
	      </form>
	      <form name="myform" action="servlet/BlogList?userid=<%=loginUser.getId()%>" method="post">
	      
  <table width="800" align="center" bgcolor="#E4EDFB">
    <tr width="100%">
	      		<td width="100%" align="center" style="font-size: 14px">
	          		<script language="javascript">document.write(getPageInfo(<%=pageObject.getTotal()%>,<%=pageObject.getPageSize()%>,<%=pageObject.getPageNo()%>,5,'images/page_img','myform'));</script>
		        </td>
	        </tr>
	      </table>
      	</form>
		<jsp:include page="common/footer.jsp" />
	</body>
</html>

⌨️ 快捷键说明

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