当前位置: 代码迷 >> IIS >> IIS7 Request format is unrecognized
  详细解决方案

IIS7 Request format is unrecognized

热度:9272   发布时间:2013-02-26 00:00:00.0
IIS7 Request format is unrecognized.

早上同事在安装程序的时候一直报错让我帮忙查一下原因,最后发现是一个网站无法打开。错误报错如下:

 

错误1:The Web server is configured to not list the contents of thisdirectory.

 

解决办法:打开IIS控制台兵器启用Directory browsing

 

 

错误2Request format is unrecognized.

 

解决办法:

 

找到Web.config文件,增加下面的信息:

 

<configuration>    <system.web>    <webServices>        <protocols>            <add name="HttpGet"/>            <add name="HttpPost"/>        </protocols>    </webServices>    </system.web></configuration>

 

原因:GET和 POST 在ASP.NET2.0或者之上的版本是默认Disabled,需要更改Web.config启用。

 

  相关解决方案