if (Request.Form["hidInfoId"] != null && Request.Form["hidActionId"] != null)
        {
            string infoid = Request.Form["hidInfoId"];
            string dltID = Request.Form["hidActionId"];
            string mm = this.Server.MapPath("/UploadFiles2/2012/2012-12/12-19/2012121913415188996.rar");            
            Response.ContentType = "application/x-zip-compressed";
            Response.TransmitFile(mm);
        }
上面的下载语句放到了一个单独的下载页面的page_load方法下面,文件地址绝对正确,可为什么在360浏览器下就是下载的是错误页面呀,下载不到该下载的文件。注意,在本地测试常用浏览器都可以,就是放到网上后,在360下就不行了,其它的浏览器都可以。郁闷中....

解决方案 »

  1.   

    可以参考:http://www.cnblogs.com/superfeeling/archive/2012/02/24/2366722.html
    另外,我遇到过在360下载只能当前窗口,无法新开窗口,但正常下载肯定没问题的。
      

  2.   

    不好意思,发错了。刚才发的是正确的,但是如果把其中的参数infoid转成整数类型时,这个下载就错误了,就是这种形式
    if (Request.Form["hidInfoId"] != null && Request.Form["hidActionId"] != null)
            {
                int infoid =Convert.ToInt32(Request.Form["hidInfoId"]);
                int dltID = Convert.ToInt32(Request.Form["hidActionId"]);
                string mm = this.Server.MapPath("/UploadFiles2/2012/2012-12/12-19/2012121913415188996.rar");            
                Response.ContentType = "application/x-zip-compressed";
                Response.TransmitFile(mm);
            }
    但是用get提交时,也可以,像这样
    if (Request.QueryString["hidInfoId"] != null && Request.QueryString["hidActionId"] != null)
            {
                int infoid =Convert.ToInt32(Request.QueryString["hidInfoId"]);
                int dltID = Convert.ToInt32(Request.QueryString["hidActionId"]);
                string mm = this.Server.MapPath("/UploadFiles2/2012/2012-12/12-19/2012121913415188996.rar");            
                Response.ContentType = "application/x-zip-compressed";
                Response.TransmitFile(mm);
            }