laravel 图片上传 intervention/image

南宫阳冰
2023-12-01

1. composer require intervention/image

2). 修改 app/config/app.php 添加 ServiceProvider:

// 将下面代码添加到 providers 数组中
'providers' => [
    // ...
    Intervention\Image\ImageServiceProvider::class,
    // ... ], // 将下面代码添加到 aliases 数组中 'aliases' => [ // ... 'Image' => Intervention\Image\Facades\Image::class, // ... ],
3 生成 config/image.php 配置文件:
php artisan vendor:publish --provider="Intervention\Image\ImageServiceProviderLaravel5"

转载于:https://www.cnblogs.com/simadongyang/p/11392552.html

 类似资料: