I have the latest WebAPI installed (v5.0.0-rc1) and have installed the latest CORS support package (v5.0.0-rc1).
GET works fine, but when sending POST, I always get:
OPTIONS http://localhost:19357/api/v1/rooms? 404 (Not Found) angular.js:10159
OPTIONS http://localhost:19357/api/v1/rooms? Origin http://localhost:8000 is not allowed by Access-Control-Allow-Origin. angular.js:10159
XMLHttpRequest cannot load http://localhost:19357/api/v1/rooms. Origin http://localhost:8000 is not allowed by Access-Control-Allow-Origin.
When I check Fiddler, only the OPTIONS request is sent - not the POST.
Here is my Register() method in WebApiConfig.cs:
public static void Register(HttpConfiguration config)
var cors = new EnableCorsAttribute("*", "*", "*");
Because EnableCorsAttribute and EnableCors() are available, the package must be installed correctly.
I had a Web.config or a Application_BeginRequest() hack, but removed it in favor of this support package.
Anyone got a solution for me?