【Asp】ASP提取任意文件二进制数据流下载

  • A+
所属分类:lcx

ASP提取任意文件二进制数据流下载,通常遇到做文件下载站点时要用到:

StrName = server.MapPath("挂机锁.exe")
Response.Buffer = True
Response.Clear
Set ADO = Server.CreateObject("ADODB.Stream")
ADO.Open
ADO.Type = 1
Set fs = Server.CreateObject("Scripting.FileSystemObject")
Set f = fs.GetFile(StrName)
intFilelength = f.size
ADO.LoadFromFile(StrName)
Response.AddHeader "Content-Disposition", "attachment; filename=" & f.name
Response.AddHeader "Content-Length", intFilelength
Response.ContentType = "application/octet-stream"
Response.BinaryWrite ADO.Read
Response.Flush
%> 

文章来源于lcx.cc:【Asp】ASP提取任意文件二进制数据流下载

相关推荐: 【VB】VB 读取/获取本机远程桌面/3389端口

    VB 读取/获取本机远程桌面/3389端口号,VB 读取本机远程桌面/3389端口号,VB 获取本机远程桌面/3389端口号,VB 读取/获取本机远程桌面端口号,VB 读取/获取本机3389端口号,VB 获取本机远程桌面端口号,VB 读取本机远程桌面端…

发表评论

:?: :razz: :sad: :evil: :!: :smile: :oops: :grin: :eek: :shock: :???: :cool: :lol: :mad: :twisted: :roll: :wink: :idea: :arrow: :neutral: :cry: :mrgreen: