Azure-functions-host: Access to XMLHttpRequest at 'http://localhost:8080/register' from origin 'http://localhost:4200' has been blocked by CORS policy: Response to preflight request doesn't pass access control check: It does not have HTTP ok status.

Created on 30 Nov 2018  路  3Comments  路  Source: Azure/azure-functions-host

I have two requests : get and post .
The GET Request is working fine via the browser but when i try the POST it mentions CORS error 403 unauthorized .
is it normal that CORS appears only in the post request ?

PS : i tried the POST with postman and it working fine

Here is the error :
"Access to XMLHttpRequest at 'http://localhost:8080/register' from origin 'http://localhost:4200' has been blocked by CORS policy: Response to preflight request doesn't pass access control check: It does not have HTTP ok status. "

Most helpful comment

Can you please explain how the issue is fixed..I am also facing same issues

All 3 comments

@slim-souissi how are you running the host in your scenario?

i configured my back to support cors and it fixed it . thanks for replying @fabiocav

Can you please explain how the issue is fixed..I am also facing same issues

Was this page helpful?
0 / 5 - 0 ratings