日期:2014-05-17 浏览次数:20817 次
<script language="javascript"> function addFile1() { var str = '<select name="bblx'+count+'" value="1"><option value="1">普通下载</option><option value="2">流畅下载</option><option value="3">高清下载</option></select>文件地址:<INPUT type="text" size="50" NAME="videourl"/><input type="button" value=" + " onclick="addFile1()"><br>' document.getElementById('MyFile').insertAdjacentHTML("beforeEnd",str) } </script> <body> <form name="form" action="Sopic_videoupadds.asp" method="post" accept-charset="utf-8"> <P id="MyFile"> <select name="bblx" value="1"><option value="1">普通下载</option><option value="2">流畅下载</option><option value="3">高清下载</option></select>文件地址:<INPUT type="text" size="50" name="videourl" class="tx1" /><input onclick="addFile1()" type="button" value=" + "><br> </P> <input type="submit" name="submit" value="上传"> <input onclick="this.form.reset()" type="button" value="重置"> </form>
<% dim name,flid,videourl name=request.form("name") flid=request.form("flid") videourl=request.form("videourl") RMB=request.form("RMB") if name="" or flid="" or videourl="" then output="各项都要填写!" else dim rs set rs=server.CreateObject("adodb.recordset") rs.open "select * from videoview",conn,1,3 Rs.addnew Rs("name")=name Rs("flid")=flid Rs("RMB")=RMB Rs.Update Rs.close Set Rs=nothing set rs=server.CreateObject("adodb.recordset") rs.open "select top 1 id from videoview order by id desc",conn,1,1 idc=rs("id") Rs.close Set Rs=nothing iCount=0 For each filefield in request.Form("videourl") filefield1=Replace(filefield,"\","/") dim ggss IF InStrRev(filefield1,".") > 0 THEN ggss = mid(filefield1,InStrRev(filefield1,".")+1) end if iCount=iCount+1 set rs=server.CreateObject("adodb.recordset") rs.open "select * from videodow",conn,1,3 Rs.addnew Rs("videourl")=filefield1 Rs("yd_size")=getFileSize(filefield1) Rs("format")=ggss if ggss="mp4" or ggss="3gp" or ggss="mp3" then Rs("gs")=1 end if Rs("videoviewid")=idc Rs("bblx")= '这里的值要怎么循环入库?? Rs.Update Rs.close Set Rs=nothing Next output="成功上传!" end if %>