yesteamtech / laravel-file-manager
A file upload/editor intended for use with Laravel 5 and CKEditor
2.0.0
2018-05-24 12:07 UTC
Requires
- php: >=5.4.0
- illuminate/support: >=4.2.0
- intervention/image: 2.*
Suggests
- ext-gd: to use GD library based image processing.
- ext-imagick: to use Imagick based image processing.
This package is auto-updated.
Last update: 2024-11-08 21:03:02 UTC
README
A files and images management user interface with file uploading support. (Works well with CKEditor and TinyMCE)
PR is welcome!
Overview
- The project was forked from tsawler/laravel-filemanager
- Customizable routes and middlewares
- Supported locales : en, fr, bg, tr, fa, es, pt-BR, tr, zh-CN, zh-TW
- Supports public and private folders for multi users
- Supports multi-level folders
- Supports using independently(see integration doc)
Documents
Upgrade guide
composer update unisharp/laravel-filemanager
php artisan vendor:publish --tag=lfm_view --force
php artisan vendor:publish --tag=lfm_config --force
(IMPORTANT: please backup your ownconfig/lfm.php
first)
Screenshots
- Independent usage example :
- List view :
- Grid view :
Events
To use events you can add a listener to listen to the events
Snippet for EventServiceProvider
protected $listen = [ ImageWasUploaded::class => [ UploadListener::class, ], ];
The UploadListener
will look like:
class UploadListener { public function handle($event) { $method = 'on'.class_basename($event); if (method_exists($this, $method)) { call_user_func([$this, $method], $event); } } public function onImageWasUploaded(ImageWasUploaded $event) { $path = $event->path(); //your code, for example resizing and cropping } }
List of events:
- Yesteamtech\Laravelfilemanager\Events\ImageWasUploaded
Credits
- All contibutors from GitHub. (issues / PR)
- Special thanks to
- @taswler the original author.
- @olivervogel for the awesome image library
- @welcoMattic providing fr translations and lots of bugfixes.
- @fraterblack TinyMCE 4 support and pt-BR translations.
- @1dot44mb tr translations.
- @Nikita240 fixing controller extending errors.
- @amin101 guide for independent use and fixes for url/directory error on Windows
- @nasirkhan bug fixes and alphanumeric filename check
- @petyots Bulgarian translation
- All @UniSharp members