Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/csharp/258.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181

Warning: file_get_contents(/data/phpspider/zhask/data//catemap/1/asp.net/31.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
ASP.NET C#在web上获取RSS XML文件时出现愚蠢的错误_C#_Asp.net_Xml_Rss - Fatal编程技术网

ASP.NET C#在web上获取RSS XML文件时出现愚蠢的错误

ASP.NET C#在web上获取RSS XML文件时出现愚蠢的错误,c#,asp.net,xml,rss,C#,Asp.net,Xml,Rss,我正在制作一个Web表单,它将访问一个站点,获取xml格式的rss提要,并将它们读入XmlTextReader中,以便在我的站点中格式化和显示 我有这条线路,负责到达另一个站点 XmlTextReader reader = new XmlTextReader(@"http://www.wired.com/threatlevel/feed/"); 当我从我的本地主机运行它时,它运行良好。但一旦它在1和1服务器上发布,它就会失败,并出现以下错误 A connection attempt faile

我正在制作一个Web表单,它将访问一个站点,获取xml格式的rss提要,并将它们读入XmlTextReader中,以便在我的站点中格式化和显示

我有这条线路,负责到达另一个站点

XmlTextReader reader = new XmlTextReader(@"http://www.wired.com/threatlevel/feed/");
当我从我的本地主机运行它时,它运行良好。但一旦它在1和1服务器上发布,它就会失败,并出现以下错误

A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond 72.246.94.16:80

Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code. 

Exception Details: System.Net.Sockets.SocketException: A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond 72.246.94.16:80

Source Error: 

An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.
你知道会是什么吗


非常感谢

您可能在1&1被出站防火墙阻止


联系1&1并要求他们禁用它,或切换到更好的主机。(你得到的是你付出的)

哈哈,这就是我害怕的答案!每次我必须和他们打交道时,我都会想起他们有多糟糕。。。。希望下次会选择更好的。谢谢好啊我找到了一些相关信息。CAS将仅授予对拥有特定CAS权限的关键资源的访问权限。在共享主机中,将授予以下权限:。。。执行HTTP请求的WebPermission,例如使用外部XML Web服务。(必须使用端口3128上的代理服务器ntproxyus.lxa.perfora.net进行访问)