I tried to save the image that comes from the POST request using laravel. but it gives me the following error.
ReflectionException on line Container.php 741: class image does not exist
I did the following things: including the fileinfo extension in the php.ini file and composer dumpautoload
but it fails, I followed the directions here
I use Laravel 5.1
my code is the same
public function saveImage(){
Image::make(Input::file('files')->getRealPath())
->resize(870, null, true, false)
->save('foo.jpg');
}
source
share