Webservice error, "The test form is only available f
发布时间:2020-12-16 23:06:19 所属栏目:安全 来源:网络整理
导读:测试webservice的时候,如果出现这个错误:"The test form is only available for requests from the local machine" 在web.config中加入以下配置,就可以解决问题。 system.web ????webServices ????????protocols ??????????add?name="HttpGet"/ ?????????
测试webservice的时候,如果出现这个错误:"The test form is only available for requests from the local machine" 在web.config中加入以下配置,就可以解决问题。 <system.web> ????<webServices> ????????<protocols> ??????????<add?name="HttpGet"/> ??????????<add?name="HttpPost"/> ????????</protocols> ????</webServices> </system.web> 原因: 在.NET Framework v1.0中,可以通过远程访问和测试一个web service,但在v1.1下,出于安全问题,这个远程调用被禁止了(不过还是可以在本地调用)。所以出现这个错误 The test form is only available for requests from the local machine (编辑:李大同) 【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容! |