I recently tries enabling CORS in Laravel 5.4 but unfortunately it doesn\'t want to work. I have included the code and the error that it\'s giving me below. Can anyone help
If none of this working, add cors on apache virtual host configuration (If you use virtual host).
Go to /etc/apache2/sites-available and add something like this gist
/etc/apache2/sites-available
then sudo a2ensite example.conf and sudo service apache2 reload ;)
sudo a2ensite example.conf
sudo service apache2 reload