日期:2014-05-18  浏览次数:20683 次

(!急!急!急)100求解http可以下载 https IE 提示 无法打开站点 请求的站点不可用或者找不到
这个是   1.1   (vs2003)写的  
    这段代码在URL是   http://xxx.xx.xxx运行没有问题,但是https://xxx.xx.xxx就不行了.IE   提示   无法打开站点     请求的站点不可用或者找不到具体是什么问题啊!
(443端口应该没有封,https访问页面没有问题但是下载不灵)

#region   from   DataGrid   To   Excel   File
public   static   void   DataGridToExcelFile(DataGrid   DataGrid1,   string   sTitle,   string   sDescription,   string   sFileName)
{

string   s   =   " ";
HttpContext.Current.Response.Clear();
HttpContext.Current.Response.Buffer   =   true;
HttpContext.Current.Response.Charset   =   "utf-8 ";
HttpContext.Current.Response.AppendHeader( "Content-Disposition ",   "attachment;filename= "   +   sFileName);
HttpContext.Current.Response.ContentEncoding   =   Encoding.GetEncoding( "utf-8 ");
HttpContext.Current.Response.ContentType   =   "application/ms-excel ";
CultureInfo   formatProvider   =   new   CultureInfo( "ZH-CN ",   true);
StringWriter   writer   =   new   StringWriter(formatProvider);
HtmlTextWriter   writer2   =   new   HtmlTextWriter(writer);
DataGrid1.RenderControl(writer2);
s   =   writer.ToString();
s   =   sTitle   +   sDescription   +   " <br> <br> "   +   s;
HttpContext.Current.Response.Write(s);
HttpContext.Current.Response.End();
}
#endregion

------解决方案--------------------
https://是安全验证的超文本传输协议
------解决方案--------------------
是不是权限的问题啊?
------解决方案--------------------
https是需要证书认证的协议,你那样写法明显不行的 而且验证方式也分几种
------解决方案--------------------
路过,不懂,帮顶一下
------解决方案--------------------
https:// 能访问.那应该不存在上面讲的证书问题.

重点看一下IE设置吧.....
------解决方案--------------------
也有可能是文件路径问题
用相对路径下载文件 有时候在不同的浏览器会出错
------解决方案--------------------
试试https://localhost能不能用,如果不行那就是ssl认证没有配通。