asp.net webApi 支持js的跨域请求
只需要在web.config的 system.webServer 添加一下代码即可
<httpProtocol>
<customHeaders>
<add name="Access-Control-Allow-Origin" value="*" />
<add name="Access-Control-Allow-Methods" value="GET, POST, PUT, DELETE" />
</customHeaders>
</httpProtocol>
定,精,简,俭