📄 all_user.jsp
字号:
<%@ taglib uri="/WEB-INF/struts-logic.tld" prefix="logic" %>
<%@ taglib uri="/WEB-INF/struts-bean.tld" prefix="bean" %>
<%@ page contentType='text/html;charset=GBK'%>
<logic:notPresent name="username">
<logic:forward name="login" />
</logic:notPresent>
<html>
<head>
<title>Untitled Document</title>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<meta http-equiv="refresh" content="30">
<script language="JavaScript" type="text/JavaScript">
function CheckForm() {
if (!chknumber(TheForm.page.value) || TheForm.page.value == "") {
alert ("请正确填写要跳到的页数!");
return(false);
}
return(true);
}
function chknumber(checkStr) {
var checkOK = "0123456789.+-";
var allValid = true;
var checkCode = 0;
for (i = 0; i < checkStr.length; i++) {
ch = checkStr.charAt(i);
if (checkOK.indexOf(ch) == -1) {
allValid = false;
break;
}
if ((ch == '+' || ch == '-') && i > 0) {
allValid = false;
break;
}
if (ch == '.') {
checkCode += 1;
if (checkCode > 1) {
allValid = false;
break;
}
}
}
return(allValid);
}
</script>
<style type="text/css">
<!--
table { font-size: 12px}
input { border-style: solid; border-top-width: 1px; border-right-width: 1px; border-bottom-width: 1px; border-left-width: 1px}
-->
</style>
</head>
<body bgcolor="#FFFFFF" text="#000000" background="images/back.gif">
<table width="596" border="0" align="right" cellpadding="0" cellspacing="0">
<tr>
<td height="44">
<div align="center"><img src="images/all_user.gif" width="289" height="55"></div>
</td>
</tr>
<tr>
<td height="15">
<hr>
</td>
</tr>
<tr>
<td height="116" valign="top">
<table width="100%" border="0" cellspacing="0" cellpadding="0">
</table>
<table width=610>
<tr bgcolor=e8e8e8>
<td width="44">序号
<td width="58">是否好友
<td width="143">使用者代号
<td width="176">使用者昵称
<td width="165">来自
<logic:present name="useronlinelist">
<logic:iterate id="useronline" name="useronlinelist" offset="0" length="15">
<tr><td width='44'><bean:write name="useronline" property="sn" /><td width='58'><logic:equal name="useronline" property="isfriend" value="0">否</logic:equal><logic:equal name="useronline" property="isfriend" value="1">是</logic:equal><td width='143'><a href="user.do?username=<bean:write name='useronline' property='username' />"><bean:write name="useronline" property="username" /></a><td width='176'><a href="user.do?username=<bean:write name='useronline' property='username' />"><bean:write name="useronline" property="fullname" /></a><td width='165'><bean:write name="useronline" property="ip" />
</logic:iterate>
</logic:present>
</table>
<div align="right">
<form name="TheForm" method="post" action="useronline.do" onSubmit="return CheckForm()">
<logic:greaterThan name="currentPage" value="1">
<a href="useronline.do?page=<bean:write name='previous' />">上一页</a>
</logic:greaterThan>
<logic:lessThan name="currentPage" value="<%=(String)request.getAttribute("pageCount") %>" >
<a href="useronline.do?page=<bean:write name='next' />">下一页</a>
</logic:lessThan>
第 <bean:write name="currentPage" /> / <bean:write name="pageCount" />
页 跳到 第
<input type="text" name="page" size="3" class="sinput">
页
<input type="submit" name="Submit" value="跳转" class="botton">
</form>
</div>
</td>
</tr>
<tr>
</tr>
</table>
<div align="right"></div>
</body>
</html>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -