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

📄 newforum.asp

📁 秘密网源代码 传闻拉了 100W风投
💻 ASP
字号:
<!-- #include file="Setup.asp" -->
<!--#include file="WoLib/Function.asp"-->
<!--#include file="WoLib/Cls_Class.asp"-->
<%
HtmlTop
if CookieUserName=empty then error("您还未<a href=Login.asp?ReturnUrl="&ReturnUrl&">登录</a>")

if request("action")="add" then
	SortOrder=10
	IsModerated=0
	IsActive=0
	GroupID=RequestInt("GroupID")

	ForumName=HTMLEncode(Request.Form("ForumName"))
	Moderated=CookieUserName
	TotalCategorys=HTMLEncode(Request.Form("TotalCategorys"))
	ForumDescription=HTMLEncode(Request.Form("ForumDescription"))
	ForumRules=HTMLEncode(Request.Form("ForumRules"))
	ForumUrl=HTMLEncode(Request.Form("ForumUrl"))
	forumlogo="images/group_logo001.jpg"

	if GroupID=0 then Alert("请先建立群组才能添加群组!")
	if ForumName="" then Alert("请输入群组名称!")
	
	sql="select * from [Wo_Forums] Where 1>2"
	Rs.Open sql,Conn,1,2
    Rs.addNew
		Rs("ParentID")=0
		Rs("SortOrder")=SortOrder
		Rs("IsModerated")=IsModerated
		Rs("IsActive")=IsActive
		Rs("GroupID")=GroupID
		Rs("ForumName")=ForumName
		Rs("Moderated")=Moderated
		Rs("TotalCategorys")=TotalCategorys
		Rs("ForumDescription")=ForumDescription
		Rs("ForumRules")=ForumRules
		Rs("ForumUrl")=ForumUrl
		Rs("DateCreated")=now()
		Rs("ForumLogo")=Forumlogo
	Rs.Update
	Rs.Close
	Set Rs = Nothing
	
	Call Wodig.MsgBox2("您的申请已经提交,请等待管理员的审核!",2,"group.asp")
end if

%>
<form method="POST" action="?action=add" name="form">
	<table cellspacing="1" width="90%" border="0" id=CommonListArea align="center">
		<tr id=CommonListTitle3>
			<td align=center colspan="2">申请群组</td>
		</tr>
		<tr id=CommonListCell>
			<td width="40%"><b>名称</b><br>版块名称</td>
			<td><input size="30" name="ForumName" value="<%=ForumName%>"> </td>
		</tr>
		<tr id=CommonListCell>
			<td><b>版面链接</b><br>在这里输入一个网址,每当窝友点击这个版面时就会链接到那个地址</td>
			<td><input type="text" name="ForumUrl" size="30" value="<%=ForumUrl%>"></td>
		</tr>
		<tr id=CommonListCell>
			<td><b>群组</b><br>选择该群的群组</td>
			<td>
				<select name="GroupID" onchange="Ajax_CallBack(false,'ParentForum','loading.asp?menu=ForumList&GroupID='+this.options[this.selectedIndex].value)">
<%
	sql="select * from [Wo_Groups] order by GroupID"
	Rs.open sql,conn,1
		do while not Rs.eof
			if Rs("GroupID")=GroupID then
				response.write "<option value="&Rs("GroupID")&" selected>"&rs("GroupName")&"</option>"
			else
				response.write "<option value="&Rs("GroupID")&">"&rs("GroupName")&"</option>"
			end if
		Rs.movenext
		loop
	Rs.close
	
%>	
</select>
			</td>
		</tr>
		<tr id=CommonListCell>
			<td><b>主题类别</b><br>添加请用“|”分隔,如:原创|转载</td>
			<td align="Left" valign="middle"><input size="40" name="TotalCategorys" value="<%=TotalCategorys%>"></td>
		</tr>
		<tr id=CommonListCell>
			<td valign="top"><b>描述</b><br>简单描述一下该版,可以使用YBB语法</td>
			<td><textarea rows="5" name="ForumDescription" cols="50"><%=ForumDescription%></textarea></td>
		
		</tr>
		<tr id=CommonListCell>
			<td valign="top"><b>规则与导读<br></b>简单描述一下该版的规则与导读,可以使用YBB语法</td>
			<td><textarea rows="5" name="ForumRules" cols="50"><%=ForumRules%></textarea></td>
		</tr>
		<tr id=CommonListCell>
			<td align="center" colspan="2"><input type="submit" value=" 保存 "></td>
		</tr>
	</table>
</form>	
<%
HtmlBottom
%>

⌨️ 快捷键说明

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