PHP code example of chuoke / image-gallery

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

    

chuoke / image-gallery example snippets



$config = [
    'default' => 'bing',

    'drivers' => [
        'pexels' => [
            'api_key' => 'your-api-key',
        ],
        'unsplash' => [
            'access_key' => 'your-access-key',
        ],
    ],
];

$imageGallery = (new \Chuoke\ImageGallery\ImageGalleryFactory($config))->gallery('pexels');

$images = $imageGallery->get();