This package provides a flexible way to upload file in Laravel application
Add this "arthur/uploader": "dev-master" package to the list of required packages, inside composer.json
Go to app/config/app.php
add to providers 'Arthur\Uploader\UploaderServiceProvider'
add to aliases 'Uploader' => 'Arthur\Uploader\Uploader'
Run composer update
Run php artisan vendor:publish to publish uploader.php config file
Run php artisan migrate to create uploaded_files table
Run php artisan make:uploader to create UploaderController.php in app\Http\Controllers folder with already existing upload logic, and upload route in routes/web.php file
You can now access Uploader with the Uploader alias.
$file should be instance of Illuminate\Http\UploadedFile and will return object instanceof Arthur\Uploader\UploadedFile.
$file should be instance of Arthur\Uploader\UploadedFile and will return array with all information about uploaded file including thumbnail url according to uploader.php config file.
$file should be instance of Arthur\Uploader\UploadedFile, $storage is related path to your storage folder. This will move file to another storage directory and update file storage field in uploaded_table
$file should be instance of Arthur\Uploader\UploadedFile and will remove file from storage,