Answers for "laravel api enable cors"

PHP
0

laravel api cors localhost issue

composer require fruitcake/laravel-cors
Posted by: Guest on September-01-2021
1

laravel api enable cors

//I always use an easy method. Just add below lines to \public\index.php file.
//You don't have to use a middleware I think.

header('Access-Control-Allow-Origin: *');  
header('Access-Control-Allow-Methods: GET, PUT, POST, DELETE, OPTIONS');
Posted by: Guest on September-15-2021

Browse Popular Code Answers by Language