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

📄 onleave.jsp

📁 本文论述了一个前台笔记本销售系统的开发过程
💻 JSP
字号:
<%@ page language="java" import="java.util.*" pageEncoding="gb2312"%>
<%@ page import="com.set.appframe.data.GenericValueObject"%>
<%@ page import="com.set.utils.WebUtils"%>
<%
	List dbList = (List) request.getAttribute("GVOLIST");
	int totalPage = 0;
	int pageNo = 0;
	int totalRecords = 0;
	String PagerString;
	totalPage = ((Integer) request.getAttribute("TotalPage"))
			.intValue();
	totalRecords = ((Integer) request.getAttribute("TotalRecords"))
			.intValue();
	pageNo = ((Integer) request.getAttribute("PageNo")).intValue();
	PagerString = (String) request.getAttribute("PagerString");
%>

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
	<head>
		<TITLE>网站在线留言</TITLE>
		<LINK href="home/john_shop.css" type=text/css rel=stylesheet>
	</head>
	<script type="text/javascript">
	function onSearch(){
	   document.location.href="/leave/LeaveAction.do?dispatch=search";
	}
    function goSearch()
	{
		document.all("dispatch").value="search";
		document.all("frmPage").submit();
	}
    function onPreviousPage(){
		document.all("ActionID").value="PreviousPage";
		document.all("dispatch").value="search";
//		initSearchCriteria();
		document.all("frmPage").submit();
	}

	function onFirstPage(){
		document.all("ActionID").value="FirstPage";
		document.all("dispatch").value="search";
//		initSearchCriteria();
		document.all("frmPage").submit();
	}

	function onLastPage(){
		document.all("ActionID").value="LastPage";
		document.all("dispatch").value="search";
//		initSearchCriteria();
		document.all("frmPage").submit();
	}

	function onNextPage(){
		document.all("ActionID").value="NextPage";
		document.all("dispatch").value="search";
//		initSearchCriteria();
		document.all("frmPage").submit();
	}

function onGoTo(pageindex)
{
 
		document.all("ActionID").value="GoPageNo";
		document.all("ctlGoPageNo").value=pageindex;
		document.all("dispatch").value="search";
//		initSearchCriteria();
		document.all("frmPage").submit();
	
}
	function onGoPageNo() {
     	gOnlyNumeric(false,false);//call only input numeric value.

		if (event.keyCode==13) {
			
			if ((document.all("ctlGoPageNo").value <= 0) || ((document.all("ctlGoPageNo").value - document.all("ctlTotalPage").value) >0)
		  	|| (document.all("ctlGoPageNo").value == document.all("ctlPageNo").value)){
		  	alert("请输入正确的页数!");
		  	return false;
		}
		document.all("ActionID").value="GoPageNo";document.all("ctlPageNo").value=document.all("ctlGoPageNo").value;
		document.all("dispatch").value="search";
//		initSearchCriteria();
		document.all("frmPage").submit();
		}
	}
</script>
	<body text=#000000 leftMargin=0 background="image/background.gif"
		topMargin=0 marginheight="0" marginwidth="0">

		<jsp:include page="../common/Top_head.jsp" flush="false"></jsp:include>

		<TABLE class=grayline
			style="TABLE-LAYOUT: fixed; WORD-BREAK: break-all" cellSpacing=0
			cellPadding=0 width=100% bgColor=#ffffff border=0>

			<TR>
				<TD height=40 width=100% colspan=4>
					&nbsp;目前位置:
					<A href="http://localhost/home/Login.jsp">首页</A> &gt; 在线留言
				</TD>
			</TR>
			<tr>
				<td colspan=4 style="BORDER-TOP: #000000 2px solid" width="100%"
					height=20>&nbsp;
					

				</td>
			</tr>

		</TABLE>
		<TABLE width=100% border=0>
			<tr>
				<td width="10%" align="center" valign="top">
					<jsp:include page="../home/load.jsp"></jsp:include><p>
						<jsp:include page="../home/search.jsp"></jsp:include>
				</td>
				<td valign=top class=blackLine>
					<IMG src="../image/s.gif">
				</td>
				<td valign=top align=center width="90%">
					<table width=100%>
						<tr>
							<td align="center" colspan="2">
								<a href="../leave/newleave.jsp"><img
										src="../image/write.gif" width="174" height="45" border=0>
								</a> &nbsp;&nbsp;&nbsp;&nbsp;
								<a href="javascript:onSearch();"><img
										src="../image/read.gif" width="98" height="22" border=0>
								</a>
							</td>
						</tr>
                        <tr>
                          <td>
                          <form action="/leave/LeaveAction.do" method=post name="frmPage">
                          <input type=hidden name="dispatch" value="search">
                           <input name="ActionID" type="hidden" value="search">
						  <input type="hidden" name="ctlTotalPage" value=<%=totalPage %>>
						  <input type="hidden" name="ctlPageNo" value=<%=pageNo %>>
                          <input type="hidden" name="ctlGoPageNo">                          
                          <table  width="100%">
                          <%
							  	if(null!=dbList) 
									{
										Iterator it = dbList.iterator();
										GenericValueObject gvo ;
										for(int j=0;it.hasNext();j++)
										{
											gvo = (GenericValueObject)it.next();
											String faceUrl="../image/face"+gvo.getItemString("FACE")+".gif";
											String pictureUrl="../image/pic"+gvo.getItemString("PICTURE")+".gif";
											
						  %>
						             <tr bordercolor="#3399FF"><td width="14%" rowspan="2"><img src="<%=pictureUrl %>" width=60 border=0></td>
						               <td width="17%" height="35" bordercolor="#3399FF" bgcolor="#9999FF"><font color="#0033FF"><%=gvo.getItemString("NAME") %></font>&nbsp;&nbsp;
						               <IMG src="<%=faceUrl %>" border=0><strong>:</strong></td>
						               <td width="69%" align=right bordercolor="#3399FF" bgcolor="#9999FF"><%=gvo.getItemString("CREATEDDATE") %></td>
						             </tr>
									 <tr><td height="33" colspan="2" bordercolor="#3399FF" bgcolor="#9999FF"><%=gvo.getItemString("CONTENT") %></td>
								     </tr>
									 <tr>
									   <td height="21" colspan="3" bordercolor="#FFFFFF">&nbsp;</td>
						    </tr>
						  <%
						   }
						 } %>
                          </table>
                          </form>
                          <span style="font-size: 14px">
	  <center>
	    <p>
          <%String str=WebUtils.getGooglePagerString(totalPage,pageNo);
	  out.println(str);
	   %>
        </p>
	  </center>
      </span>
                          </td>
                        </tr>                          
					</table>
				</td>
			</tr>
		</TABLE>
		<jsp:include page="../home/bottom.jsp" flush="false"></jsp:include>
	</body>
</html>

⌨️ 快捷键说明

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