upload images using laravel application on LEMP Ubuntu 16.04 return cors origin

Hello Every body I have project on my droplet consist of 1- backend application using laravel 5.4 2- front end using angular js 1.4.8 my issue when I try upload Images return to me this message PUT 500 (Internal Server Error)

/#/TeacherEdtiProfile:1 XMLHttpRequest cannot load No 'Access-Control-Allow-Origin' header is present on the requested resource. Origin '' is therefore not allowed access. The response had HTTP status code 500.

notice : I called already package in laravel enabeld cors orging notice 2 : this path I save to my image : /var/www/panakeis_project/html/public/

Show comments

Submit an answer

This textbox defaults to using Markdown to format your answer.

You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!

Sign In or Sign Up to Answer

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

Want to learn more? Join the DigitalOcean Community!

Join our DigitalOcean community of over a million developers for free! Get help and share knowledge in Q&A, subscribe to topics of interest, and get courses and tools that will help you grow as a developer and scale your project or business.


I’ve had a similar problem in the past. To solve the problem I used the following package:

Regards, Bobby