📄 addarticle.jsp
字号:
<%@ page contentType="text/html; charset=gb2312" language="java" errorPage="" %>
<%@ taglib uri="/WEB-INF/fellow-taglib.tld" prefix="fellow" %>
<%@ include file="checkLogin.jsp" %>
<%@ include file="init.jsp" %>
<html>
<head>
<link rel="stylesheet" href="style.css">
<script language="JavaScript" type="text/JavaScript">
function checkInput()
{
if (document.form1.sortId.value=="")
{
alert("没有分类,无法添加 !");
document.form1.sortId.focus();
return false;
}
if (document.form1.title.value=="")
{
alert("标题不能为空!");
document.form1.title.focus();
return false;
}
if (document.form1.content.value=="")
{
alert("内容不能为空!");
document.form1.content.focus();
return false;
}
}
</script>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title>无标题文档</title>
</head>
<body background="../images/admin_bg.gif">
<div align="center">
<table width="90%" height="90%" border="1" cellpadding="2" cellspacing="0" style="border-collapse: collapse" bordercolor="#006D91" bgcolor="#FFFFFF">
<tr>
<td><div align="center">
<form action="/news/servlet/util.AddArticleServlet" method="post" name="form1" onSubmit="return checkInput()">
<table border="1" cellpadding="0" cellspacing="0" style="border-collapse: collapse" bordercolor="#006D91" width="100%">
<tr>
<td width="20%" bgcolor="#FBFBFB"><p style="margin-top: 2"> <img border="0" src="../images/02.gif"> 增加文章</td>
<td width="87%" bgcolor="#5BBFFF" align="center"><p style="margin-top: 2"></td>
</tr>
</table>
<p>
<table width="100%" border="0" cellpadding="0" cellspacing="0" style="border-collapse: collapse" bordercolor="#006D91">
<tr>
<td width="20%" height="27"><div align="right"><img border="0" src="../images/04.gif">选择分类:</div></td>
<td colspan="2" width="87%"><select name="sortId">
<%
Iterator sorts = myNews.getAllSorts().iterator();
while(sorts.hasNext()){
SortDetails sort = (SortDetails)sorts.next();
%>
<option value="<%=sort.getSortId()%>" selected><%=sort.getSortName()%></option>
<%
}
%>
</select></td>
</tr>
<tr>
<td height="33"><p align="right" style="margin-top: 2"><img border="0" src="../images/04.gif">文章标题:</td>
<td colspan="2"><input type="text" name="title"></td>
</tr>
<tr>
<td valign="top"><div align="right"><img border="0" src="../images/04.gif">文章内容:</div></td>
<td colspan="2"><fellow:webEditor id="content" resourcePath="/admin/webEditor/" currentDir="/admin/"
styleName="Office2003" language="sc" moduleName="full"
rebuild="false" width="100%" height="500" simpleMode="false"> </fellow:webEditor> </td>
</tr>
<tr>
<td colspan="2" width="20"> </td>
<td colspan="3" width="87%"><div align="center">
<input type="submit" name="Submit" value="提交">
<input type="reset" name="Submit" value="重置">
</div></td>
</tr>
</table>
</form>
</div></td>
</tr>
</table>
</div>
</body>
</html>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -