B
B
BMaks_N12019-05-01 23:46:02
API
BMaks_N1, 2019-05-01 23:46:02

Can't set up CORS for ASP.NET MVC?

I'm trying to make a web api with the ability to upload a file to the server, I found the project
https://cloud.mail.ru/public/82Gs/e65JAeGce
but you can't make cross-domain requests, I tried to fasten CORS -
[System.Web.Http.Cors.EnableCors( origins: "*", headers: "*", methods: "*")]
All request fails, what could be wrong? Or is it the client?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
A
Ascar, 2019-05-02
@Ascar

services.AddCors

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question