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

📄 type.jsp

📁 本书由浅入深、循序渐进地介绍了MVC的体系结构和如何构建一个基于MVC的Web框架
💻 JSP
字号:
<%@ page contentType="text/html; charset=GBK" language="java" import="java.sql.*" errorPage="" %>
<%@ page import="java.sql.*,java.util.*,javax.servlet.*,
		 javax.servlet.http.*,java.text.*,java.math.*,com.myContent.vo.ContentType,com.gd.mvc.io.InfoInAndOut,com.gd.mvc.io.impl.GdInfoInAndOut"
%>
<%! public static final String _AppId = "type"; %>
<%
	InfoInAndOut infoOut = (request.getAttribute("infoOut") == null) ? new GdInfoInAndOut() : (InfoInAndOut)request.getAttribute("infoOut");
	String msg = infoOut.get("msg") == null ? "" : (String)infoOut.get("msg");
	List contentTypeList = infoOut.get("contentTypeList") == null ? new ArrayList(): (ArrayList)infoOut.get("contentTypeList");
	ContentType contentType = infoOut.get("contentType") == null ? new ContentType() : (ContentType)infoOut.get("contentType");	
	String username = infoOut.get("username") == null ? "" : (String)infoOut.get("username");
	String userId = infoOut.get("userId") == null ? "" : (String)infoOut.get("userId");
%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=GBK">
<title>内容类别设定</title>
<style type="text/css">
<!--
.style1 {
	color: #FF0000;
	font-weight: bold;
}
body {
	background-color: #FFFFFD;
	font-family: Verdana, "宋体";
	font-size: 12px;
	font-style: normal;
}
-->
</style>
<script language=Javascript>
function submit(target, action) {
    form1.target = target;   
    form1.action.value = action;
    form1.submit();
}
function openWin(name, url, width, height) {
	var screenWidth = screen.width;
	var screenHeight = screen.height;
	var w;
    	w = window.open(url, name, "width="+width+",height="+height+",menubar=no,resizable=yes,toolbar=no,directories=no,location=no,scrollbars=yes,status=yes,copyhistory=0");
	w.moveTo((screenWidth-width)/2, (screenHeight-height)/2);
	w.focus();
}
function goExit() {
	window.close();
}
function check(action) {
	submit('<%="type_"+session.getId()%>',action);
}
</script>
</head>

<body>
<form name="form1" method="post" action="/myContent/myContent/type.do">
  <table width="776" border="1">
    <tr>
      <td height="38" colspan="2"><div align="center">内容类别设定『<span class="style1">消息提示:<%=msg%></span>』</div></td>
    </tr>
    <tr>
      <td height="44"><div align="right">已存在的内容类别:</div></td>
      <td>
      <%
      int m = 1;
      for (int i = 0; contentTypeList != null && contentTypeList.size() > i; i++) {
      		ContentType contentTypeTemp = (ContentType)contentTypeList.get(i);
      %>
      <%=m++ + "、" + contentTypeTemp.getContentTypeId() + "_" + contentTypeTemp.getContentTypeName() + ","%>
      <%
      }
      %>
    </tr>
    <tr>
      <td width="320"><div align="right"> 内容类别代码:</div></td>
      <td width="440"><input type="text" name="contentTypeId_contentType" value="<%=contentType.getContentTypeId()%>"></td>
    </tr>
    <tr>
      <td><div align="right">内容类别名称:</div></td>
      <td><input type="text" name="contentTypeName_contentType" value="<%=contentType.getContentTypeName()%>"></td>
    </tr>
    <tr>
      <td colspan="2"><div align="center"></div>        <div align="center">
      <input type="button" name="button" value="新增" onClick="return check('insert')">
      <input type="button" name="button" value="修改" onClick="return check('update')">
      <input type="button" name="button" value="删除" onClick="return check('delete')">
      </div></td>
    </tr>
  </table>
  <input type="hidden" name="username" value="<%=username%>">
  <input type="hidden" name="userId" value="<%=userId%>">
   <input type="hidden" name="action" value="">
</form>
<script language=Javascript>
    window.name = "<%="type_"+session.getId()%>";     
</script>
</body>
</html>

⌨️ 快捷键说明

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