Download the PHP package clapp/imagerepository without Composer
On this page you can find all versions of the php package clapp/imagerepository. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Please rate this library. Is it a good library?
Informations about the package imagerepository
clapp/imagerepository

Usage example (in Laravel)
API reference
ImageRepository::put($imageContents)ImageRepository::get($key, $width = 500, $height = 500)ImageRepository::remove($key)ImageRepository::flush()
ImageRepository::__construct($storagePrefix = "", $storageDisk = null, $cacheDisk = null, ImageManager $imageManager = null)
Create a new ImageRepository instance.
Params:
$storagePrefix:stringa prefix to allow multiple collections on the same $storageDisk and $cacheDisk - e.g."user-profile-pictures"$storageDisk:Illuminate\Contracts\Filesystem\Filesystema disk to store the original images$cacheDisk:Illuminate\Contracts\Filesystem\Filesystema disk to store the generated image thumbnails$imageManager:Intervention\Image\ImageManagerImageManager to use for image manipulation
ImageRepository::put($imageContents)
Store an image into the ImageRepository instance.
Params:
$imageContents:mixedany image format that Intervention\Image\ImageManager::make() can parse
Returns:
string$key that can be used to retrieve the image fromget()
ImageRepository::get($key, $width = 500, $height = 500)
Params:
$key:stringkey fromput()OR an absolute path to an image file on your local disk (for placeholders)$width:intfit the image into this width (default: 500)$height:intfit the image into this height (default: 500)
Returns:
stringpath to the generated image from the base of the $cacheDisk - can be put immediately into laravel'sasset()function
ImageRepository::get($key, Closure $transform, Closure $transformId)
Params:
$key:stringkey fromput()OR an absolute path to an image file on your local disk (for placeholders)$transform:Closureuse this function to apply custom transformations to the image$transformId:Closureuse this function to generate a unique string for the custom transformation - the same transformation should have the same unique string
Example:
Returns:
stringpath to the generated image from the base of the $cacheDisk - can be put immediately into laravel'sasset()function
All versions of imagerepository with dependencies
PHP Build Version
Package Version
The package clapp/imagerepository contains the following files
Loading the files please wait ...