addrule.jsp

来自「使用jsp+Servlet,采用MVC模式,实现了一典型小型电子商务网站的全过程」· JSP 代码 · 共 100 行

JSP
100
字号
<%@ page language="java" import="java.util.*" pageEncoding="gb2312"%>
<!--%@ include file="/include/top.jsp" %-->
<HTML> 
	<HEAD>
		<title>添加新规则</title>
		<link href="../../css/style.css" rel="stylesheet" type="text/css">
<script language="JavaScript">
<!--
function check()
{ 
	    if(document.rule.ruleid.value=="")
     {
	   window.alert("请输入规则ID!");
	   document.rule.ruleid.focus();
	   return false;
	   }
	   if(document.rule.rule.value=="")
     {
	   window.alert("请输入规则描述!");
	   document.rule.rule.focus();
	   return false;
	   }
	   
	  if(document.rule.start.value=="")
     {
	   window.alert("请输星级!");
	   document.rule.start.focus();
	   return false;
	   }
	return true;
}
//-->
</script>
	</HEAD>
	
	<body>
		<form  action="../../servlet/RuleConfirmServlet" id="rule" method="post" name="rule" onSubmit="return check()">
			<table height="100%" cellSpacing="0" cellPadding="0" width="100%" align="center" border="0">
					<tr>
						<td vAlign="top" width="19" bgColor="#f5f5f5"><IMG src="../../images/main_01.gif"></td>
						<td width="1" bgColor="#e0e0e0"><IMG src="../../images/space.gif"></td>
						<td class="main02_bg" vAlign="top">
							<table width="100%" border="0" cellspacing="0" cellpadding="0">
								<tr>
									<td class="main02_top">&nbsp;</td>
								</tr>
							</table>
							
        <table width="100%" height="31" border="0" align="center" cellpadding="0" cellspacing="0">
          <tr>
									
            <td vAlign="bottom" width="40" height="31"><IMG src="../../images/dot21.gif"></td>
									<td valign="bottom">添加新规则</td>
									<td valign="bottom" align="right">
										<a class="a_main02" href="#"> &nbsp;</a>	
										<a class="a_main02">&nbsp;</a>										
									</td>
								</tr>
							</table>
							<!--this site-->
							
        <table width="632" border="0" align="center" class="main02_table" cellpadding="0" cellspacing="0" height="78">
          <tr>
			<td width="20%" height="25" class="main02_listbg1"><img src="../../images/dot06.gif">规则ID</td>
					<td class="main02_listbg2">
					<input type="text" name="ruleid" class="main02_box" maxlength="40">
				  </td>
				</tr>		
            <tr>
            <td width="20%" height="25" class="main02_listbg1"><img src="../../images/dot06.gif">规则描述</td>
					<td class="main02_listbg2">
					<input type="text" name="rule" class="main02_box" maxlength="40">
				  </td>
				</tr>
				<tr>
					
            <td width="20%" height="25" class="main02_listbg1"><img src="../../images/dot06.gif">星级</td>
					<td class="main02_listbg2">
					<input type="text" name="start" class="main02_box" maxlength="40">
				  </td>
				</tr>
				<tr>
					<td width="20%" class="main02_listbg1"><IMG src="../../images/dot06.gif">
					<input type="submit" value="提交" name="submit">
					<input type="reset" value="重置" name="reset">
					</td>
					<td class="main02_listbg2">&nbsp;</td>
				</tr>
			</table>
					</td>
					</tr>
			</table>
			
		</form>
	</body>
</HTML>

  
  

⌨️ 快捷键说明

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