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

📄 writetopic.asp

📁 仿雅虎论坛静态生成html版 后台管理:admin/admin.asp 用户名:admin 密码:admin TOP/top.htm 顶部模板 left.htm 左边树形菜单模板
💻 ASP
字号:
<html>
<head>
  <title>可授限资源设置窗口</title>
  <style type="text/css">
	 .quote{margin:0px 0px;border:1px solid #CCCCCC;padding:0px; background:#cccccc;}
	  TD {FONT-SIZE: 9pt; FONT-FAMILY: "宋体", "Arial", "Times New Roman"}
  </style>
</head>
<body leftMargin=0 topMargin=0 marginheight="0" marginwidth="0" class=quote >
<!--#include file="Char.asp"-->
<!--#include file="../conn.asp"-->
<script>
function movetocenter()
{
var h=document.body.clientHeight;
var w=document.body.clientWidth;
window.moveTo((screen.availWidth-w)/2,(screen.availHeight-h)/2);
}
//延时,以准确获得相关参数。
setTimeout("movetocenter()",100);
</script>
<script language="javascript">
function isok(myform){
   if (myform.filename.value.length<1 || myform.opendress.value.length<1 || myform.sizenum.value.length<1)
     {
        alert("打*号的内容不能为空!");
	    return(false);
	 }
	 //self.opener.newfile.nl.value+=myform.explain.value;
 }
 function isok2(myform){
   if (myform.filename.value.length<1 || myform.downdress.value.length<1 || myform.sizenum.value.length<1)
     {
        alert("打*号的内容不能为空!");
	    return(false);
	 }
	 //self.opener.newfile.nl.value+=myform.explain.value;
 }
</script>

<script language="javascript">
function insertsmilie(smilieface){
	self.opener.newfile.nl.value=smilieface
}
</script>

<%
lx=Request.QueryString("lx")
if lx=0 then
    sublx=Request.form("sublx")
    filename=Request.Form("filename")
    filelx=Request.Form("filelx")
    filesize=Request.Form("filesize")
    playos=Request.Form("playos")
    selectx=Request.Form("select")
    sizenum=Request.Form("sizenum")
    explain=Request.Form("explain")
    opendress=Request.Form("opendress")
    username=Request.Cookies("username")
    if Request.Form("downdress")="" then downdress="无" else downdress=Request.Form("downdress") end if
    
    Set rs = Server.CreateObject("ADODB.Recordset")
    sql="SELECT top 1 * FROM DownFile "
    rs.open sql,conn,1,3
    rs.AddNew
    rs("Name")=FileName
    rs("Type")=filelx
    rs("Size")=filesize
    rs("YyPt")=playos
    rs("PlayDress")=opendress
    rs("DownDress")=downdress
    rs("Bz")=server.HTMLEncode(explain)
    rs("TJ")=selectx
    rs("TJNum")=sizenum
    rs("User")=Request.Cookies("UserName")
    rs("Lx")=Sublx
    rs.Update
    FileID=rs("ID")
    rs.Close
    set rs=nothing
    set conn=nothing
    
    Response.Write "<script>self.opener.newfile.nl.value+=""[BTDOWN="&cstr(FileID)&"]""</script>"
    
    Response.Write "<br><br><br><br><center>提交成功&nbsp;&nbsp;"
    Response.Write "<input type=Button name=fj value=""关闭窗口"" onclick=window.close();return false></center>"
else

if lx=1 then
%>
    <form onSubmit="return isok(this)" METHOD="POST" action="WriteTopic.asp?lx=0" id=form1 name=form1>
    <table width=340 border=0>
    <input type="hidden" name="sublx" value="1">
    <tr><td width=60>影视名称:*</td><td><input type=text name=filename size=20></td></tr>
    <tr><td>影视格式:</td><td><input type=text name=filelx size=10></td></tr>
    <tr><td>文件大小:</td><td><input type=text name=filesize size=10></td></tr>
    <tr><td>播放平台:*</td><td>    
    <select name="playos" size="1">
    <option value="RealPlay">RealPlay</option>
    <option value="MediaPlay">MediaPlay</option>
    <option value="QuickTime">QuickTime</option>
    </select>
    </td></tr>
    <tr><td>播放地址:*</td><td><input type=text name=opendress size=30></td></tr>
    <tr><td>下载地址:</td><td><input type=text name=downdress size=30></td></tr>
    <tr><td valign=top>相关描述:</td><td><TEXTAREA class=fminpt ROWS=5 COLS=28 name="explain"></textarea></td></tr>
    <tr><td>观看条件:*</td><td>
    <select name="select" size="1">
    <option value="没有任何条件">没有任何条件</option>
    <option value="支付金钱">支付金钱</option>
    <option value="声望限止">声望限止</option>
    <option value="积分限止">积分限止</option>
    <option value="经验限止">经验限止</option>
    <option value="帖子数限止">帖子数限止</option>
    </select>
    </td></tr>
    <tr><td>条件数值:*</td><td><input type=text name=sizenum size=10 value=0> 如果没有条件,此项可为0</td></tr>
    </table>
<%
else
    if lx=2 then
%>
    <form onSubmit="return isok(this)" METHOD="POST" action="WriteTopic.asp?lx=0" id=form2 name=form2>
    <table width=340 border=0>
    <input type="hidden" name="sublx" value="2">
    <tr><td width=60>音乐名称:*</td><td><input type=text name=filename size=20></td></tr>
    <tr><td>音乐格式:</td><td><input type=text name=filelx size=10></td></tr>
    <tr><td>文件大小:</td><td><input type=text name=filesize size=10></td></tr>
    <tr><td>播放平台:*</td><td>
    <select name="playos" size="1">
    <option value="RealPlay">RealPlay</option>
    <option value="MediaPlay">MediaPlay</option>
    </select>
    </td></tr>
    <tr><td>播放地址:*</td><td><input type=text name=opendress size=30></td></tr>
    <tr><td>下载地址:</td><td><input type=text name=downdress size=30></td></tr>
    <tr><td valign=top>相关描述:</td><td><TEXTAREA class=fminpt ROWS=5 COLS=28 name="explain"></textarea></td></tr>
    <tr><td>播放条件:*</td><td>
    <select name="select" size="1">
    <option value="没有任何条件">没有任何条件</option>
    <option value="支付金钱">支付金钱</option>
    <option value="声望限止">声望限止</option>
    <option value="积分限止">积分限止</option>
    <option value="经验限止">经验限止</option>
    <option value="帖子数限止">帖子数限止</option>
    </select>
    </td></tr>
    <tr><td>条件数值:*</td><td><input type=text name=sizenum size=10 value=0> 如果没有条件,此项可为0</td></tr>
    </table>
<%
    else
        if lx=3 then
        %>
    <form onSubmit="return isok2(this)" METHOD="POST" action="WriteTopic.asp?lx=0" id=form3 name=form3>
    <table width=340 border=0>
    <input type="hidden" name="sublx" value="3">
    <tr><td width=60>文件名称:*</td><td><input type=text name=filename size=20></td></tr>
    <tr><td>文件格式:</td><td><input type=text name=filelx size=10></td></tr>
    <tr><td>文件大小:</td><td><input type=text name=filesize size=10></td></tr>
    <tr><td>应用平台:</td><td><input type=text name=playos size=20></td></tr>
    <tr><td>下载地址:*</td><td><input type=text name=downdress size=30></td></tr>
    <tr><td valign=top>相关描述:</td><td><TEXTAREA class=fminpt ROWS=5 COLS=28 name="explain"></textarea></td></tr>
    <tr><td>下载条件:*</td><td>
    <select name="select" size="1">
    <option value="没有任何条件">没有任何条件</option>
    <option value="支付金钱">支付金钱</option>
    <option value="声望限止">声望限止</option>
    <option value="积分限止">积分限止</option>
    <option value="经验限止">经验限止</option>
    <option value="帖子数限止">帖子数限止</option>
    </select>
    </td></tr>
    <tr><td>条件数值:*</td><td><input type=text name=sizenum size=10 value="0"> 如果没有条件,此项可为0</td></tr>
    </table>
        <%
        else
            Response.Write "参数错误"
        end if
    end if
end if 
%>
<center><input type=Submit value="确定" name=add >&nbsp; <input type="reset" name="Clear" value="重写"></center>
</form>
<%end if%>
</body>
</html>

⌨️ 快捷键说明

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