laravel-eloquent-files maintained by shridharkaushik29
Description
File Handling with Eloquent Models in Laravel
Author
Last update
2024/11/11 08:10
(2.0.x-dev)
License
Downloads
283
Eloquent Files
Installation using Composer:
composer require shridharkaushik29/laravel-eloquent-files
Usage:
In your eloquent model use \Shridhar\EloquentFiles\HasFile trait and create a method for accessing file like below:
Here "image_path" is the attribute/column name on which you want to assign the path of the uploaded file, default is "file_path".
The second argument accepted by the file_info() method is the array of the following options.