开发者

Web.config fails on staging environment, but runs locally?

开发者 https://www.devze.com 2023-03-26 08:18 出处:网络
I\'m running a staging environment on a dedicated ASP .NET server that has worked just fine until recently, where I added the following to the web.config file:

I'm running a staging environment on a dedicated ASP .NET server that has worked just fine until recently, where I added the following to the web.config file:

<location path="dashboard/api/ManageProjects.asmx">
<system.web>
  <webServices>开发者_运维技巧
    <protocols>
      <add name="HttpGet"/>
    </protocols>
  </webServices>
</system.web>
</location>
<location path="administration/api/ManageProjects.asmx">
<system.web>
  <webServices>
    <protocols>
      <add name="HttpGet"/>
    </protocols>
  </webServices>
</system.web>
</location>

I honestly have no idea of why this would ruin the staging environment at all, but it gives me an error 500.


I fixed the issue by removing the location-content from the web.config file and then added the following, under the web.config's section:

<webServices>
  <protocols>
    <clear />
    <add name="HttpGet"/>
    <add name="HttpPost"/>
  </protocols>
</webServices>
0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号