📄 board_add.asp
字号:
<%
'==============================================================================
'软件名称:星空社区 VER 1.0.15
'当前版本:starcity club V1.0.15
'最新更新:2004.9
'==============================================================================
'Copyright (C) 2002-2004 Googln.com All rights reserved.
'商业注册联系:010-64410364
'技术支持QQ:6370639(限商业用户)
'程序开发:Googln Studio(BeiJing)
'Email:Avram@163.com
'论坛支持:星空社区(http://www.starcity.cn/bbs)
'官方网站:www.Googln.com 演示站点:www.starcity.cn/bbs 都市星空:www.starcity.cn 阳光商城:www.sunmall.com.cn
'==============================================================================
'免费版本请在首页保留版权信息,并做上本站LOGO友情连接
'都市星空在线保留此程序的法律追究权利
'==============================================================================
%>
<!--#include file="../include/conn.asp"-->
<!--#include file="checkuser.asp"-->
<%
dim sql,sql2
dim rs
dim rs2
dim i
set rs=server.createobject("adodb.recordset")
sql="select * from db_class order by id"
rs.open sql,conn,1,1
set rs2=server.createobject("adodb.recordset")
sql2="select * from db_board order by dateandtime"
rs2.open sql2,conn,1,1
if err.Number<>0 then
err.clear %>
<center> 数据库操作失败!</center>
<%else%>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<link rel="stylesheet" type="text/css" href="../include/style.css">
<title>版面管理</title>
<script language="javascript">
<!--
function test(form) {
if ((form.options.value == "rename" && form.reTitle.value == "") || (form.options.value == "new" && form.newTitle.value == ""))
{alert("信息不能为空!");return false;}
if (form.options.value == "del")
{return confirm("将同时删除该版面中的所有内容!是否继续?");}
return true;
}
//-->
</script>
<body>
<table width="95%" border="0" align="center" cellpadding="0" cellspacing="0">
<tr>
<td> </td>
</tr>
<tr>
<td><table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td width="30" height="30"><div align="center"><img src="images/pic0.gif" width="14" height="11"></div></td>
<td class="1">管理版面</td>
</tr>
</table></td>
</tr>
<tr>
<td><table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td width="13"><img src="images/pic1_0.gif" width="13" height="23"></td>
<td bgcolor="#ADBEE7"> </td>
<td width="13"><img src="images/pic1_1.gif" width="13" height="23"></td>
</tr>
</table></td>
</tr>
<tr>
<td><table width="100%" border="0" align="center" cellpadding="0" cellspacing="0">
<tr>
<td bgcolor="#ADBEE7"><form method="POST" action="class_managersave.asp" align="center" language="javascript" onsubmit="return test(this);">
<input type="hidden" name="options" value>
<table border="0" cellpadding="0" cellspacing="0" width="98%" align="center">
<tr>
<td><strong>版面管理</strong></td>
</tr>
<tr>
<td> </td>
</tr>
<tr>
<td><p>类别:
<select name="subject" size="1"
style="font-size: 9pt">
<%
if rs.eof and rs.bof then
response.write "<option value=>请增加类别"
else
Do while not rs.eof
response.write "<option value='" + Cstr(rs("id")) + "'>" + rs("name") + "</option>"
rs.MoveNext
Loop
end if
%>
</select>
<input type="submit" value="删除" name="B2" onclick="form.options.value='del'" >
</td>
</tr>
<tr align="center">
<td><br>
</td>
</tr>
<tr align="center">
<td><p align="left">新名字:
<input type="text" name="reTitle" size="20" class=smallinput>
<input type="submit" value="改名" name="B1" onclick="form.options.value='rename'">
</td>
</tr>
<tr align="center">
<td><br>
</td>
</tr>
<tr align="center">
<td><p align="left">新类别:
<input type="text" name="newTitle" size="20" class=smallinput>
<input type="submit" value="新增" name="B3" onclick="form.options.value='new'">
</td>
</tr>
</table>
</form>
<form method="POST" action="class_managersave_.asp" align="center" language="javascript" onsubmit="return test(this);">
<input type="hidden" name="options" value>
<table border="0" cellpadding="0" cellspacing="0" width="98%" align="center">
<tr>
<td align="center"><hr>
<div align="left"><b>子版面管理</b></div></td>
</tr>
<tr align="center">
<td><br>
</td>
</tr>
<tr>
<td><div align="center">
<center>
<p align="left">子版面:
<select name="subject" size="1"
style="font-size: 9pt">
<%
if rs2.eof and rs2.bof then
response.write "<option value=>请增加版面"
else
Do while not rs2.eof
response.write "<option value='" + Cstr(rs2("boardid")) + "'>" + rs2("boardname") + "</option>"
rs2.MoveNext
Loop
end if
%>
</select>
<input type="submit" value="删除" name="B2" onclick="form.options.value='del'">
</center>
</div></td>
</tr>
<tr align="center">
<td><br>
</td>
</tr>
<tr align="center">
<td><p align="left">子版面:
<input type="text" name="reTitle" size="20" class=smallinput>
版主:
<input name="reboardmaster" type="text" id="reboardmaster" size="20">
在
<select name="id" size="1"
style="font-size: 9pt">
<%
if rs.eof and rs.bof then
response.write "<option value=>请增加类别"
else
rs.MoveFirst
Do while not rs.eof
response.write "<option value='" + Cstr(rs("id")) + "'>" + rs("name") + "</option>"
rs.MoveNext
Loop
end if
%>
</select>
中
<input type="submit" value="改名" name="B1" onclick="form.options.value='rename'">
</td>
</tr>
<tr align="center">
<td><br>
</td>
</tr>
<tr align="center">
<td><p align="left">新版面:
<input type="text" name="newTitle" size="20" class=smallinput>
版主
<input name="newboardmaster" type="text" id="newboardmaster" size="20">
在
<select name="psubject" size="1"
style="font-size: 9pt">
<%
if rs.eof and rs.bof then
response.write "<option value=>请增加类别"
else
rs.MoveFirst
Do while not rs.eof
response.write "<option value='" + Cstr(rs("id")) + "'>" + rs("name") + "</option>"
rs.MoveNext
Loop
end if
%>
</select>
中
<input type="submit" value="新增" name="B3" onclick="form.options.value='new'">
</td>
</tr>
</table>
</form>
</td>
</tr><tr><td><table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td width="10" valign="top"><img src="images/pic1_2.gif" width="10" height="18"></td>
<td bgcolor="#ADBEE7"> </td>
<td width="10" valign="top"><img src="images/pic1_3.gif" width="10" height="18"></td>
</tr>
</table></td></tr>
</table></td>
</tr>
</table>
</body>
</html>
<%
rs.close
rs2.close
set rs=nothing
set rs2=nothing
conn.close
set conn=nothing
end if
%>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -