在无外网的情况下,如何下载大型ASF文件,且在下载时不要被系统改扩展名(不支持软件下载)

tvruuiqpl1314520 2008-05-04 10:25:36
比如:TVR_2008-04-24_14-43-45_01.asf这个文件有700M以上,如何下载,而且在下载时不会被系统改扩展名,局域网内下载(无外网),不支持下载软件.
...全文
132 10 打赏 收藏 转发到动态 举报
写回复
用AI写文章
10 条回复
切换为时间正序
请发表友善的回复…
发表回复
tvruuiqpl1314520 2008-05-05
  • 打赏
  • 举报
回复
还是这位朋友,说的正确
[Quote=引用 7 楼 mailto520 的回复:]
用ftp
[/Quote]
tvruuiqpl1314520 2008-05-05
  • 打赏
  • 举报
回复

我用过这个函数下载过,文件过大,IIS有些反应缓慢,下载小文件是不错的选择

[Quote=引用 8 楼 jobsen123 的回复:]
<%
'On Error Resume Next
Response.Buffer = true
Response.Clear
Dim ID,DownUrl
ID=Request.QueryString("ItemID")
ID=CSQL(HTML(ID),1)
If Not CKID(ID,"DownLoads","ID="&ID) Then
Response.Redirect("Errors.asp?u=Index.asp&e=")
End If
End If
If Conn.Execute("select SoftDownUrl from DownLoads where id="&ID&"").Eof And Conn.Execute("select SoftDownUrl from DownLoads where id="&ID&…
[/Quote]
tvruuiqpl1314520 2008-05-04
  • 打赏
  • 举报
回复
IE,将asf的文件改为asx的文件
[Quote=引用 3 楼 jiangsheng 的回复:]
系统指的是什么?IE没有乱改扩展名的习惯。
[/Quote]
tvruuiqpl1314520 2008-05-04
  • 打赏
  • 举报
回复
我用的就是http ://192.168.0.121/T/112.asf下载的,但是下载下来的是112.asx
现在要112.asf,而不是,112.asx
我们的文件一般都很大的700M以上,但又不支持软件下载
[Quote=引用 4 楼 chinmo 的回复:]
那就只有使用http的下载了
[/Quote]
  • 打赏
  • 举报
回复
那就只有使用http的下载了
蒋晟 2008-05-04
  • 打赏
  • 举报
回复
系统指的是什么?IE没有乱改扩展名的习惯。
tvruuiqpl1314520 2008-05-04
  • 打赏
  • 举报
回复
就是说如何下载文件大小很大的ASF文件,不要通过BT,迅雷等下载软件来完成下载,而且,在下载的时候不要被系统改扩展名
[Quote=引用 1 楼 ghostzp 的回复:]
I can't understand what you said
[/Quote]
若白师妹 2008-05-04
  • 打赏
  • 举报
回复
I can't understand what you said
jobsen123 2008-05-04
  • 打赏
  • 举报
回复
<%
'On Error Resume Next
Response.Buffer = true
Response.Clear
Dim ID,DownUrl
ID=Request.QueryString("ItemID")
ID=CSQL(HTML(ID),1)
If Not CKID(ID,"DownLoads","ID="&ID) Then
Response.Redirect("Errors.asp?u=Index.asp&e=")
End If
End If
If Conn.Execute("select SoftDownUrl from DownLoads where id="&ID&"").Eof And Conn.Execute("select SoftDownUrl from DownLoads where id="&ID&"").Bof Then
Response.ContentType="text/html;charset=gb2312"
Response.Write("<script>alert(""无效的下载参数!"");</script>")
Response.End()
Else
DownUrl=Conn.Execute("select SoftDownUrl from DownLoads where id="&ID&"")(0)
End If
Dim SoftUrl
Dim Fso,Files,FileSize
Dim objStream,ContentType,FileName
If DownUrl<>"" Then
SoftUrl=server.MapPath(DownUrl)
'Response.Write SoftUrl
Set Fso=Server.CreateObject("Scripting.FileSystemObject")
Set Files=Fso.GetFile(SoftUrl)
FileSize=Files.size
FileName=Files.name
Set Files=Nothing
Set Fso=Nothing
'Response.Write FileName
Set objStream = Server.CreateObject("ADODB.Stream")
objStream.Open
objStream.Type = 1
objStream.LoadFromFile SoftUrl
Select Case lcase(Right(FileName, 3))
Case ".rm"
ContentType = "audio/x-pn-realaudio"
End Select
Select Case lcase(Right(FileName, 4))
Case ".asf"
ContentType = "video/x-ms-asf"
Case ".avi"
ContentType = "video/avi"
Case ".doc"
ContentType = "application/msword"
Case ".zip"
ContentType = "application/zip"
Case ".xls"
ContentType = "application/vnd.ms-Excel"
Case ".gif"
ContentType = "image/gif"
Case ".jpg", "jpeg"
ContentType = "image/jpeg"
Case ".wav"
ContentType = "audio/wav"
Case ".mp3"
ContentType = "audio/mpeg3"
Case ".mpg", "mpeg"
ContentType = "video/mpeg"
Case ".rtf"
ContentType = "application/rtf"
Case ".htm", "html"
ContentType = "text/html"
Case ".txt"
ContentType = "text/plain"
Case Else
ContentType = "application/octet-stream"
End Select
Response.Buffer=True
Response.Clear
Response.AddHeader "Content-Disposition", "attachment; filename=" & FileName
Response.AddHeader "Content-Length", FileSize
Response.Charset = "UTF-8"
Response.ContentType = ContentType
Response.BinaryWrite objStream.Read
Response.Flush
response.Clear()
objStream.Close
Set objStream = Nothing
End If
%>
mailto520 2008-05-04
  • 打赏
  • 举报
回复
用ftp

28,391

社区成员

发帖
与我相关
我的任务
社区描述
ASP即Active Server Pages,是Microsoft公司开发的服务器端脚本环境。
社区管理员
  • ASP
  • 无·法
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧