PHP code example of ktc / cdn

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

    

ktc / cdn example snippets


'providers' => [
//....
//...
//.
CDN\CDNServiceProvider::class

'disks' => [
//....
//...
//.
'sftp' => [
	'driver'   => 'sftp',
	'host' => env('CDN_SSH_HOST'),
	'port' => 22,
	'username' => env('CDN_SSH_USERNAME'),
	'password' => '',
	'privateKey' => env('CDN_SSH_PRIVATE_KEY_PATH'),
	'root' => env('CDN_BASE').'/'.env('CDN_BASE_SUBDIRECTORY'),
]

'storage' => 
	[
		'disk' => 'sftp',
	],