PHP code example of smallunit / image
1. Go to this page and download the library: Download smallunit/image library. Choose the download type require. 2. Extract the ZIP file and open the index.php. 3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
smallunit / image example snippets
$this->app->bind("image", function () {
return new Image(config('config_file_name.versions'));
});
namespace App\Providers;
use Illuminate\Support\ServiceProvider;
use Image\Image;
class AppServiceProvider extends ServiceProvider
{
/**
* Bootstrap any application services.
*
* @return void
*/
public function boot()
{
$this->app->bind("image", function () {
return new Image(config('services.versions'));//Enter the you config_file , version
});
}
......................................