mro / thumbnail
There is no license information available for the latest version (dev-main) of this package.
This Package Use To Create Thumbnail Image in Laravel (Writer:MohammadRezaOrdooni)
dev-main
2022-07-25 09:10 UTC
This package is auto-updated.
Last update: 2025-07-25 15:34:49 UTC
README
Thumbnail Can Use To Create Image Thumbnail In Laravel.
Installation
composer require mro/thumbnail
Add the following code to providers in config/app.php
Mro\Thumbnail\ThumbnailServiceProvider::class,
Add the following code to aliases in config/app.php
'Thumbnail'=>Mro\Thumbnail\ThumbnailFacade::class,
Usage
public function store(Request $request) { # create function arguments: create($_FILES['image'],$quality,$newWidth,newHeight); # the defaults are $quality=100 & $newWidth=300 & newHeight=300. # Images will be upload in "public/uploads/thumbnails/" directory. $image=\Thumbnail::create($request->image,100,200,200); Post::create([ 'image'=>$image, ]); }
Contributing
I hope that will be usefull for you.