亚洲免费乱码视频,日韩 欧美 国产 动漫 一区,97在线观看免费视频播国产,中文字幕亚洲图片

      1. <legend id="ppnor"></legend>

      2. 
        
        <sup id="ppnor"><input id="ppnor"></input></sup>
        <s id="ppnor"></s>

        ASP保存遠(yuǎn)程文件到本地

        字號(hào):


            <%
            Function SaveRemoteFile(LocalFileName,RemoteFileUrl)
            SaveRemoteFile=True
            dim Ads,Retrieval,GetRemoteData
            Set Retrieval = Server.CreateObject("Microsoft.XMLHTTP")
            With Retrieval
            .Open "Get", RemoteFileUrl, False, "", ""
            .Send
            If .Readystate<>4 then
            SaveRemoteFile=False
            Exit Function
            End If
            GetRemoteData = .ResponseBody
            End With
            Set Retrieval = Nothing
            Set Ads = Server.CreateObject("Adodb.Stream")
            With Ads
            .Type = 1
            .Open
            .Write GetRemoteData
            .SaveToFile server.MapPath(LocalFileName),2
            .Cancel()
            .Close()
            End With
            Set Ads=nothing
            End Function
            %>
            <%
            '以下為調(diào)用示例:
            remoteurl="http://pic02.newdu.com/uploads/202504/02/logo2812.gif"'遠(yuǎn)程文件名(絕對(duì)全路徑)
            localfile=Replace(Replace(Replace(Now(),"-","")," ",""),":","")&Right(remoteurl,4)'本機(jī)文件名(可自定義)
            If SaveRemoteFile(localfile,remoteurl)=True Then
            Response.Write("成功保存:"&localfile)
            End If
            %>