https://www.youtube.com/watch?v=PozYTvmgcVE
1. Add middleware
php artisan make:middleware Cors
return $next($request)
->header('Access-Control-Allow-Origin', '*')
->header('Access-Control-Allow-Methods', 'GET, POST, PUT, DELETE, OPTIONS');
2. Register middleware as a route middleware
3. Use middleware in routes which support CORS
Subscribe to:
Post Comments (Atom)
How to enable CORS in Laravel 5
https://www.youtube.com/watch?v=PozYTvmgcVE 1. Add middleware php artisan make:middleware Cors return $next($request) ->header('Acces...
-
Today we are going to build another restful web service in eclipse using gson library. When client makes a request, the application queries ...
-
To import Excel data, first you need to have a Excel reader. It should be accurate enough to interpret Excel data as expected. There 's ...
No comments:
Post a Comment