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

📄 forum_manager.asp

📁 商会 商会 商会 商会 商会 商会 商会 商会 商会 商会 商会 商会 商会
💻 ASP
字号:
<%@ Language=VBScript%>
<%
Response.Buffer=true
Response.Expires=0
%>
<!-- #include file="../dsn.asp" -->
<%
keyno=Request.QueryString("keyno")
if keyno="" then Response.End

set cn = Server.CreateObject("ADODB.Connection")
cn.Open(mycnstr)
set rs = Server.CreateObject("ADODB.Recordset")
set rs2 = Server.CreateObject("ADODB.Recordset")

htmlname="forum_manager.asp?keyno="+keyno
tablename="forum"	
%>
<html>
<head>
<title>帖子管理</title>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<style type="text/css">
<!--
body {font-size: 12px; color: #000; font-family: 宋体}
td {font-size: 12px; color: #000; font-family: 宋体;line-height:130%}

.t1 {font:12px 宋体;color=000000} 
.t2 {font:12px 宋体;color:ffffff} 
.t3 {font:12px 宋体;color:336699} 
.t4 {font:12px 宋体;color:ff0000} 
.bt1 {font:14px 宋体;color=000000} 
.bt2 {font:14px 宋体;color:ffffff} 
.bt3 {font:14px 宋体;color:336699} 
.bt4 {font:bold 16px 宋体;color:maroon} 

.td1 {font-size:12px;line-height:20px;text-align:right;background-color:#ffffff;color:#000000}
.td2 {font-size:12px;line-height:20px;text-align:left;background-color:#ffffff;color:#000000;}
.td3 {font-size:12px;line-height:20px;text-align:left;background-color:#ffffff;color:#000000;}

A:link {color: #000077}
A:visited {color: #000077}
A:hover {color: #ff0000}
-->
</style>
</head>
<body bgcolor=#fefefe topmargin=10>
<%
bz=1

if Request.ServerVariables("REQUEST_METHOD")="POST" then
	bz=0
	flag=trim(Request.Form("flag"))
	topflag=trim(Request.Form("topflag"))

	rs.Open "select classcode,topflag,flag from "+tablename+" where keyno="&keyno,cn,1,3
	if not rs.EOF then
		classcode=trim(rs("classcode"))		
		rs("topflag")=topflag
		rs("flag")=flag
		rs.Update
	end if	
	rs.Close

	Response.Write("<script language=Javascript>")
	Response.Write("window.opener.location.reload();")
	Response.Write("window.close();")
	Response.Write("</script>")
end if	
if bz>=1 then
	sqltext="select * from "+tablename+" where keyno="&keyno
	rs.Open sqltext,cn,1,1
	if not rs.EOF then
		title=trim(rs("title"))
		flag=trim(rs("flag"))
		usercode=trim(rs("usercode"))
		topflag=trim(rs("topflag"))
		creadate=rs("creadate")
		ipaddress=trim(rs("ipaddress"))
		grade=rs("grade")
	else
		Response.End	
	end if	
%>

  <table width="100%" border="0" cellspacing="0" cellpadding="0" align="center">
	<tr><td>
	<%if seekname="" then%>
		主题:<font style="font-size:12px;color:000000"><b><%=server.HTMLEncode(title)%></b></font> 
	<%end if%>	
	</td></tr>
	<tr><td><hr size=1></td></tr>
	<tr bgcolor="#527c72"><td height=18><font class=t2>具体内容</font><br>
	</td></tr>
	<tr><td height=2></td></tr>
 </table>
 <table width="100%" border="0" cellspacing="0" cellpadding="0" align="center">
 <form action="<%=htmlname%>" method=post name=editform autocomplete = "off">
	<tr><td class=td1 width=70>创建日期:</td>
		<td class=td2>
			<font color=800000><%=creadate%></font>
		</td></tr>
	<tr><td class=td1 width=70>IP地址:</td>
		<td class=td2>
			<font color=800000><%=ipaddress%></font>
		</td></tr>
	<tr><td class=td1 width=70>发帖人:</td>
		<td class=td2>
			<font color=800000><%=usercode%></font>
		</td></tr>
	<tr><td class=td1 width=70>帖子性质:</td>
		<td class=td2>
		<%if grade=1 then%>
		<input type=radio name="flag" value="0" <%if flag="0" then Response.Write("checked") end if%>>普通帖
		<input type=radio name="flag" value="1" <%if flag="1" then Response.Write("checked") end if%>>精华帖
		<input type=radio name="flag" value="2" <%if flag="2" then Response.Write("checked") end if%>>热帖
		&nbsp;
		<%else%>
		<input type=hidden name=flag value="<%=flag%>">	
		<%end if%>
		</td></tr>
	<tr><td class=td1 width=70>目前状态:</td>
		<td class=td2>
		<%if grade=1 then%>
		<input type=radio name="topflag" value="0" <%if topflag="0" then Response.Write("checked") end if%>>不置顶
		<input type=radio name="topflag" value="1" <%if topflag="1" then Response.Write("checked") end if%>>置顶
		<input type=radio name="topflag" value="2" <%if topflag="2" then Response.Write("checked") end if%>>总置顶
		&nbsp;
		<%else%>
		<input type=hidden name=topflag value="<%=topflag%>">	
		<%end if%>
		</td></tr>
</table>	
<table width="100%" border="0" cellspacing="0" cellpadding="0" align="center">
	<tr><td width=100 align=right height=50></td>
		<td><input type="submit" name="submit" value="确认提交">&nbsp;&nbsp;&nbsp;&nbsp;
		&nbsp;&nbsp;<a href="Javascript:window.close()">[关闭窗口]</a>
		</td>
	</tr>
</form>
</table>	
<%
end if
%>
<body>
</html>

⌨️ 快捷键说明

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