“调用未定义的方法 Intervention\Image\Image::make()”

MJ *_*SAN 2 php laravel

当我在 localhost 中使用 Laravel Intervention 图像时,它工作正常,但是当在我的控制面板中上传实时服务器时,它不起作用......

在此处输入图片说明

Mr *_*med 5

在 config/app.php

在 $providers 数组中添加此包的服务提供者。

Intervention\Image\ImageServiceProvider::class
Run Code Online (Sandbox Code Playgroud)

将此包的外观添加到 $aliases 数组中。

'Image' => Intervention\Image\Facades\Image::class
Run Code Online (Sandbox Code Playgroud)

根据此链接http://image.intervention.io/getting_started/installation

或在您的控制器的头部安装后添加它:-

use Intervention\Image\ImageManagerStatic as Image;
Run Code Online (Sandbox Code Playgroud)