PHP code example of servd / craft-remote-assets
1. Go to this page and download the library: Download servd/craft-remote-assets 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/ */
servd / craft-remote-assets example snippets
return [
'use' => 's3Config',
's3Config' => [
'region' => 'eu-west-1',
'bucket' => 'yourbucketname',
'root' => 'defaultKeyPrepend',
'key' => 's3APIKey',
'secret' => 's3APISecret'
],
'gsConfig' => [
'bucket' => 'yourbucketname',
'root' => 'defaultKeyPrepend',
'projectId' => 'yourProjectId',
'keyFilePath' => '/path/to/serviceworker/creds/file.json'
]
];