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

📄 regmanger.jsp

📁 电子商城
💻 JSP
字号:
<%@ page contentType="text/html; charset=GBK" language="java"%>
<%@ taglib prefix="c" uri="/WEB-INF/c.tld" %> 
<%@ taglib prefix="fmt" uri="/WEB-INF/fmt.tld" %>
<c:if test="${userList==null}">
	<c:redirect url="/servlet/RegManagerServlet" />
</c:if>
<html>
	<head>
		<meta http-equiv="Content-Type" content="text/html; charset=GBK" />
		<meta http-equiv="pragma" content="no-cache" />
		<meta http-equiv="Cache-Control" content="no-cache, must-revalidate" />
		<meta http-equiv="expires" content="Wed, 26 Feb 1970 08:21:57 GMT" />
		<title>注册用户管理</title>
	</head>
<script language="javascript" type="text/javascript">
	function isLock(suser,slock){
		location.href="<c:url value='/servlet/RegManagerServlet?action=lock&suser="+suser+ "&slock="+slock+"'/>";
	}
	<!--分页处理-->
		function submit(pageNum){
			var pageValue=showForm.curPage.value;
			if(pageNum==1){
				pageValue=1;
			}else if(pageNum==2&&pageValue>1){
				pageValue--;
			}else if(pageNum==3&&pageValue<${totalPage}){
				pageValue++;	
			}else if(pageNum==4){
				pageValue=${totalPage};		
			}
			showForm.curPage.value=pageValue;
			showForm.submit();
		}
</script>
<body>
<c:if test="${empty userList}">
	<table width="100%" align="center">
				<tr>
					<td align="center">
					<br>
					<br>
					<br>
					<br>
					<strong>对不起,暂无注册用户信息!请等待用户注册!</strong>
					<br>
					<br>
					<br>
					<br>
					</td>
				</tr>
	</table>
</c:if>
<c:if test="${!empty userList}">
<form method="get" action="/lmhshop/servlet/RegManagerServlet" name="showForm">
			<input type="hidden" id="curPage" name="curPage" value="${curPage}" />
			<table width="100%">
				<tr align="center">
					<th width="14%" align="right" nowrap scope="row">
						用户名:					</th>
					<th width="18%" align="left" nowrap scope="row">
						<c:choose>
							<c:when test="${action==null}">
							<input name="suser" type="text" id="suser" value="${param.suser}" >
							</c:when>
							<c:when test="${action!=null}">
								<input name="suser" type="text" id="suser" value="" >
							</c:when>
						</c:choose>		 	 
				  </th>
					<th width="11%" align="right" nowrap scope="row">真实姓名:</th>
					<th width="36%" align="left" nowrap scope="row">
		    	  <input name="sname" type="text" id="sname" value="${param.sname}" >			        </th>
					<th width="21%" nowrap scope="row">
						  <input name="Search" type="submit" id="Search" value="查询" />
					   			  
				  &nbsp; <input name="resetReg" type="reset" id="resetReg" value="重置"></th>
			    </tr>
  </table>
</form>


<table width="100%" border="1">
                  <tr>
                    <th width="14%" scope="row">用户名</th>
                    <th width="15%" scope="row">真实姓名</th>
                    <th width="13%" scope="row">性别</th>
                    <th width="18%" scope="row">注册时间</th>
					 <th width="27%" scope="row">是否冻结</th>
                     <th width="13%" scope="row">操作</th>
                  </tr>
				  <c:forEach items="${userList}" var="userBean">				  	
                  <tr>
                   <th scope="row">${userBean.suser}</th>
                    <th scope="row">${userBean.sname}</th>
                    <th scope="row">${userBean.ssex}</th>
                    <th scope="row">${userBean.dregdate} </th>
					 <th  scope="row">${userBean.slock==1?"是":"否"}
					</th>
                    <th scope="row">
					<c:if test="${userBean.slock=='0'}">
						<a href="#" onClick="isLock('${userBean.suser}',1);" >账号冻结 </a>
					</c:if>
					<c:if test="${userBean.slock=='1'}">
						<a href="#" onClick="isLock('${userBean.suser}',0);" >账号解冻 </a>
					</c:if>
					</th>
                  </tr>
				  </c:forEach>
    </table>

<table width="100%" border="1">
							<tr>
								<td align="center" valign="middle">共有${countAll}条记录数
									&nbsp;&nbsp; |&nbsp; &nbsp;
									 ${curPage}/${totalPage}
								 	&nbsp;&nbsp; |&nbsp;&nbsp;&nbsp;&nbsp;
									<c:if test="${curPage!=1}">
									&nbsp;<a href="#" onClick="submit(1);return false;">首页</a>
								  	&nbsp; <a href="#" onClick="submit(2);return false;">上一页</a>
									</c:if>
									<c:if test="${curPage!=totalPage}">
								 	 &nbsp; <a href="#" onClick="submit(3);return false;">下一页</a>
								 	 &nbsp; <a href="#" onClick="submit(4);return false;">尾页</a>
								  	</c:if>
							  </td>
							</tr>
	</table>
	</c:if>
</body>
</html>

⌨️ 快捷键说明

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