I'm getting really frustrated with jsonp or cors etc.
jsonp results on jquery thinking it's an error if it's just a status code that comes back, and no body. It also thinks that an error code coming back should have an error with status 200 so you can't even determine which is which.
So then I try cors, and WebAPI is intercepting my DelegatingHandler on any options request somehow and with the results that get fired back, all major browsers never go past the options request.
So then i put a ton of stuff in my web.config to force the headers:
<customHeaders>
<add name="Access-Control-Allow-Origin" value="https://beta.mobilemone.com" />
<add name="Access-Control-Allow-Headers" value="content-type, accept, authorization, origin, referer, user-agent" />
<add name="Access-Control-Allow-Methods" value="GET, POST, PUT, DELETE, OPTIONS" />
<add name="Access-Control-Allow-Credentials" value="true"/>
<add name="Access-Control-Max-Age" value="1728000"/>
</customHeaders>
Which gets it further, but still gets a "cancelled" result on the jquery ajax request that finally gets called.
How do I get cors to work properly with web api?
Thanks!