PHP code example of intervention / image-laravel

1. Go to this page and download the library: Download intervention/image-laravel 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/ */

    

intervention / image-laravel example snippets


use Intervention\Image\Laravel\Facades\Image;

Route::get('/', function () {
    $image = Image::read('images/example.jpg');
});
bash
php artisan vendor:publish --provider="Intervention\Image\Laravel\ServiceProvider"