Код: Выделить всё
Intervention \ Image \ Exception \ NotReadableException
Unable to find file ().
Код: Выделить всё
if ($request->hasFile('image')) {
$image = $request->file('image');
$filename = 'food' . '-' . time() . '.' . $image->getClientOriginalExtension();
$location = public_path('images/');
Image::make($image)->resize(800, 400)->save($location);
$food->image = $filename;
}
Код: Выделить всё
if ($request->hasFile('image')) {
$image = $request->file('image');
$filename = 'food' . '-' . time() . '.' . $image->getClientOriginalExtension();
$location = public_path('images/');
$request->file('image')->move($location, $filename);
$food->image = $filename;
}
Спасибо.
Подробнее здесь: https://stackoverflow.com/questions/465 ... -find-file
Мобильная версия