1. Go to this page and download the library: Download carlos-mg89/phpflickr 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/ */
carlos-mg89 / phpflickr example snippets
$flickr = new \Samwilson\PhpFlickr\PhpFlickr($apiKey, $apiSecret);
$storage = new \OAuth\Common\Storage\Memory();
$flickr->setOauthStorage($storage);
$verifier = '<9-digit code stripped of hyphens and spaces>';
$accessToken = $flickr->retrieveAccessToken($verifier);
// Create storage.
$storage = new \OAuth\Common\Storage\Memory();
// Create the access token from the strings you acquired before.
$token = new \OAuth\OAuth1\Token\StdOAuth1Token();
$token->setAccessToken($accessToken);
$token->setAccessTokenSecret($accessTokenSecret);
// Add the token to the storage.
$storage->storeAccessToken('Flickr', $token);