在C#中,新建一个webservice,默认是post类型的。如果需要支持Get请求,需要对web.config文件进行配置

  <system.web>
    <compilation debug="true" targetFramework="4.6.1"/>
    <httpRuntime targetFramework="4.6.1"/>
    <webServices>
      <protocols>
        <add name="HttpGet"/>
        <add name="HttpPost"/>
      </protocols>
    </webServices>
  </system.web>

 

 posted on 2017-05-09 12:54  Just_Do  阅读(1539)  评论(0编辑  收藏  举报