|
@@ -20,7 +20,8 @@ class UploadController extends Controller
|
|
|
|
|
|
|
|
|
$filePath = $request->file('image')->getRealPath();
|
|
|
- if (in_array($kuoname, ['jpg', 'gif', 'png'])) {
|
|
|
+ Log::debug('文件类型'.$kuoname);
|
|
|
+ if (in_array($kuoname, ['jpg', 'jpeg', 'gif', 'png'])) {
|
|
|
$width = Image::make($filePath)->width();
|
|
|
$height = Image::make($filePath)->height();
|
|
|
|
|
@@ -49,8 +50,9 @@ class UploadController extends Controller
|
|
|
for ($i = 0; $i < $fileCount; $i++) {
|
|
|
$kuoname = $files[$i]->getClientOriginalExtension();
|
|
|
$filePath = $files[$i]->getRealPath();
|
|
|
+ Log::debug('文件类型'.$kuoname);
|
|
|
|
|
|
- if (in_array($kuoname, ['jpg', 'gif', 'png'])) {
|
|
|
+ if (in_array($kuoname, ['jpg', 'jpeg', 'gif', 'png'])) {
|
|
|
$width = Image::make($filePath)->width();
|
|
|
$height = Image::make($filePath)->height();
|
|
|
|