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

📄 picupload.asp

📁 类似于baidu的百度知道
💻 ASP
字号:
<style type="text/css">
<!--
body {
margin-left: 0px;
margin-top: 0px;
margin-right: 0px;
margin-bottom: 0px;
}
TD {
FONT-SIZE: 9pt; LINE-HEIGHT: 150%; FONT-FAMILY: 宋体
}
-->
</style>
<%


Dim upset
upset=6 ''设置最多同时上传文件数
%>
<script>

function uploadframe(num)
{
var obj=parent.document.getElementById("ad");
if (parseInt(obj.height)+num>=24) {
obj.height = parseInt(obj.height) + num;
document.getElementById("Setupload").style.display="";
document.getElementById("allupload").style.display="none";
}
}
function setid()
{
str='';
if(!window.ftiwen.upcount.value)
window.ftiwen.upcount.value=1;
if(window.ftiwen.upcount.value><%=upset%>){
alert("您最多只能同时上传<%=upset%>个文件!");
window.ftiwen.upcount.value = <%=upset%>;
setid();
}
else{
for(i=1;i<=window.ftiwen.upcount.value;i++)
str+='文件'+i+':<input type="file" name="file'+i+'" style="width:200"><br>';
window.upid.innerHTML=str+'<br>';

var num=i*16
var obj=parent.document.getElementById("ad");
if (parseInt(obj.height)+num>=24) {
obj.height = 24 + num; 
}
}
}
</script>
<table border=0 cellspacing=0 cellpadding=0 style="width:100%;height:100%" bgcolor="#F0F6FD">
<form name="ftiwen" method="post" action="picupfile.asp" enctype="multipart/form-data">
<tr>
<TD width="347" valign=top id="upid">
<input type="file" name="file1" width=200 value="" size="40"></TD>
<td valign=top width=45>
<input type="submit" name="Submit" value="上传">
</td>
<td width="135" valign=top id=allupload>
<% if upset > 1 then %>
<input type="button" name="setload" onClick="uploadframe(25);" value="批量上传">
<% end if %>
</td>
<td width="468" valign=top>
<div id=Setupload style="display:none">
<% if upset > 1 then %>
设置上传的个数
<input type="text" value="1" name="upcount" style="width:40">
<input type="button" name="Button" onClick="setid();" value="设定"><br>(每次可以同时上传<font color="#FF0000"><%=upset%></font>个文件)
<% end if %>
</div>
</TD>
</tr>
</form>
</table>
</body>
</html>

⌨️ 快捷键说明

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