PHP code example of biigle / flysystem-elements
1. Go to this page and download the library: Download biigle/flysystem-elements 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/ */
biigle / flysystem-elements example snippets
use Biigle\Flysystem\Elements\ElementsAdapter;
use GuzzleHttp\Client;
$client = new Client([
'base_uri' => 'https://elements.example.com',
'headers' => [
'Authorization' => 'Bearer my-elements-api-token',
],
]);
$adapter = new ElementsAdapter($client);
$exists = $adapter->fileExists('.projects/path/to/file.jpg');
var_dump($exists);
// bool(true);