📄 editmast.jsp
字号:
<%@ page contentType="text/html; charset=gb2312" language="java" import="java.sql.*" errorPage="" %>
<jsp:useBean id="con" scope="page" class="numb1.com.db"/>
<jsp:useBean id="ht" scope="page" class="numb1.com.Dohtml"/>
<%
String bdid=request.getParameter("bdid");
String bbsid=request.getParameter("bbsid");
String bdname="";
String table="";
String title="";
String txt="";
String bdsql="select btable,name from board where id="+bdid;
ResultSet bd=con.query(bdsql);bd.next();
if(bd.getRow()==0){
out.print("<meta http-equiv=\"refresh\" content=\"1;URL=index.jsp\"><center><font color=#FF0000><strong>该版不存在,参数错误或该版以被删除</strong></font></center>");
}else{
table=bd.getString(1);
bdname=con.getStr(bd.getString(2));
String sql="select title,txt from "+table+" where id="+bbsid;
ResultSet rs=con.query(sql);rs.next();
if(rs.getRow()!=0){
title=con.getStr(rs.getString(1));
txt=con.getStr(rs.getString(2));
}
%>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title>编辑</title>
<SCRIPT LANGUAGE="JavaScript">
<!--
function checkmast(theform)
{
if (theform.title.value=="")
{
alert("请输入标题!");
theform.title.focus();
return false;
}
if (theform.text.value=="")
{
alert("请输入内容!");
theform.text.focus();
return false;
}
}
-->
</script>
<script language="JavaScript" src="img/add.js"></script>
<style type="text/css">
<!--
.style1 {color: #FFFFFF}
td{font-size:13px;}
a:link{text-decoration:none;color:#0000ff}
a:visited{text-decoration:none;color:#0000ff}
a:hover{text-decoration:underline;color:#96CCFE}
body {
font-size:13px;
margin-top: 3px;
}
.style2 {color: #0000FF}
-->
</style>
</head>
<body><table width="660" border="0" align="center">
<tr>
<td><div align="right" style="font-size:12px "> [<a href="index.jsp" target="_parent">论坛首页</a>]
<% out.print(" [<a href=main.jsp?id="+bdid+"><font color=#FF0000>"+bdname+"</font></a>]");%>
[<font color="#FF0000">编辑帖子</font>] </div></td>
</tr>
</table>
<form name="form1" method="post" action="action/acteditmast.jsp" onSubmit="return checkmast(this)">
<table width="660" border="0" align="center" bgcolor="#7188e0">
<tr bgcolor="#FFFFFF">
<td colspan="2"><table width="100%" border="0" cellspacing="1">
<tr>
<th bgcolor="#7188e0"><span class="style1">回 贴</span></th>
</tr>
</table></td>
</tr>
<tr bgcolor="#FFFFFF">
<td width="13%" height="22"><div align="right"><strong>主 题:</strong></div></td>
<td width="83%"> <input name="title" type="text" id="title" value="<%=title%>" size="50" style="BORDER: #7188e0 1px solid;color:#1818FF;">
<input name="onshow" type="checkbox" id="onshow" value="1" onclick=show()>
<span id="word">多彩文本</span></td>
</tr>
<tr bgcolor="#FFFFFF">
<td height="22"><div align="right"><strong>类 型:</strong></div></td>
<td><span class="form">
<INPUT name=class type=radio value=a>
普通
<INPUT name=class type=radio value=b>
原创
<INPUT name=class type=radio value=c>
贴图
<INPUT name=class type=radio value=d>
转贴 </span></td>
</tr>
<tr bgcolor="#FFFFFF" id="color" style="display: none">
<td><div align="right"><strong>多彩文本:</strong></div></td>
<td> <img src="img/i.gif" width="24" height="24"> <img src="img/bold.gif" width="24" height="24"> <img src="img/img.gif" width="24" height="24"> <img src="img/url.gif" width="24" height="24"> <img src="img/flash.gif" width="24" height="24"> <img src="img/email.gif" width="24" height="24"> <img src="img/mp3.gif" width="23" height="22"> <img src="img/mtv.gif" width="23" height="22"></td>
</tr>
<tr bgcolor="#FFFFFF">
<td valign="top"><div align="right"><strong>正 文:</strong></div></td>
<td> <textarea name="text" cols="68" rows="10" style="BORDER: #7188e0 1px solid; background:#f8f8f8; color:#1818FF; overflow:auto;"><%=txt%></textarea></td>
</tr>
<tr bgcolor="#FFFFFF">
<td height="22"><div align="right"><strong>签名:</strong></div></td>
<td><input name="pn" type="radio" value="penname1">
<a href="#" onClick="window.open('admin/show_pn.php?id=<? echo $userid;?>&pn=pn1','face','toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars=1,top=150,left=100,width=360,height=210');">第一签名</a>
<input type="radio" name="pn" value="penname2">
<a href="#" onClick="window.open('admin/show_pn.php?id=<? echo $userid;?>&pn=pn2','face','toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars=1,top=150,left=100,width=360,height=210');">第二签名</a>
<input type="radio" name="pn" value="no">
<span class="style2">不使用签名</span></td>
</tr>
<tr bgcolor="#FFFFFF">
<td colspan="2"><div align="center">
<input type="submit" name="Submit" value="提交">
<input name="bdid" type="hidden" id="bdid" value="<%=bdid%>">
<input name="bbsid" type="hidden" id="bbsid" value="<%=bbsid%>">
<input type="reset" name="Submit" value="重置">
</div></td>
</tr>
</table>
</form>
</body>
</html><% }%>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -