Monday, March 19, 2018

Laravel 5.6 Cors: Response for preflight has invalid HTTP status code 500 - development

Laravel 5.6 Cors: Response for preflight has invalid HTTP status code 500

I am using Angular 5 for the client. When I make a call to my https server on EC2 I get the Response for preflight has invalid HTTP status code 500 error. This is despite the fact that I have cors configured on my server both in apache and as a middleware using barryvdh/laravel-cors. OPTIONS is enabled in the middleware. When that didn’t’ work I even created a separate middleware for the preflight calls but that didn’t help either.

Allow Methods GET, POST, PUT, DELETE, OPTIONS is set in Cors.php middleware, config/cors and the virtual host.

I have researched pretty much every possible post but still no success. Any tips?



from Laravel Questions and Answers https://laravelquestions.com/laravel/laravel-5-6-cors-response-for-preflight-has-invalid-http-status-code-500/
via Lzo Media

No comments:

Post a Comment