文件末尾加上
Response.ContentType="*/*"
Response.AddHeader "Content-Disposition","attachment;filename=""" & 文件名 & """"
Response.Write 文件内容

解决方案 »

  1.   

    高人,用ASP确实是。
    但是
    请问,什么原理了?
      

  2.   

    Response.ContentType="*/*"
    Response.AddHeader "Content-Disposition","attachment;filename=""" & 文件名 & """"
    Response.Write 文件内容
    请标注释!
      

  3.   

    <script>
    function DownURL(strRemoteURL,strLocalURL)
    {
    try
    {
    var xmlHTTP=new ActiveXObject("Microsoft.XMLHTTP");
    xmlHTTP.open("Get",strRemoteURL,false);
    xmlHTTP.send();
    var adodbStream=new ActiveXObject("ADODB.Stream");
    adodbStream.Type=1;//1=adTypeBinary
    adodbStream.Open();
    adodbStream.write(xmlHTTP.responseBody);
    adodbStream.SaveToFile(strLocalURL,2);
    adodbStream.Close();
    adodbStream=null;
    xmlHTTP=null;
    //OpenFile(strLocalURL);
    }
    catch(e)
    {
    window.confirm("下载URL出错!");
    }
    //window.confirm("下载完成.");
    }
    </script>
    需要降低IE属性,有时看ADODB.Stream是否禁用.
      

  4.   

    asp和php的此功能代碼我有,其他語言沒有
    如果要的話,可email聯係:[email protected]