laravel-admin 上传图片配置

在config/filesystems.php中添加:
‘disks‘ => [

‘local‘ => [
    ‘driver‘ => ‘local‘,
    ‘root‘ => storage_path(‘app‘),
],

‘public‘ => [
    ‘driver‘ => ‘local‘,
    ‘root‘ => storage_path(‘app/public‘),
    ‘url‘ => env(‘APP_URL‘).‘/storage‘,
    ‘visibility‘ => ‘public‘,
],

‘s3‘ => [
    ‘driver‘ => ‘s3‘,
    ‘key‘ => env(‘AWS_KEY‘),
    ‘secret‘ => env(‘AWS_SECRET‘),
    ‘region‘ => env(‘AWS_REGION‘),
    ‘bucket‘ => env(‘AWS_BUCKET‘),
],

//主要是添加这里
‘admin‘ => [
‘driver‘ => ‘local‘,
‘root‘ => public_path(‘upload‘),
‘visibility‘ => ‘public‘,
‘url‘ => env(‘APP_URL‘).‘/public/upload/‘,
],

],

laravel-admin 上传图片配置

上一篇:纯CSS七大居中方法 前端王睿


下一篇:memcached 和服务器的 local cache(比如 PHP 的 APC、 mmap 文件等)相比,有什么优缺点?