1. Go to this page and download the library: Download jakubboucek/psync 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/ */
jakubboucek / psync example snippets
return [
'agentUrl' => 'https://example.com/psync-agent-XXXXXX.php', // public URL of the agent (used as-is)
'privateKey' => 'base64…', // from install, keep secret
'syncRoot' => '', // top of the synchronized tree ('' = this directory)
'agentDir' => 'www', // where the agent file is deployed ('' = sync-root)
'agentFile' => 'psync-agent-XXXXXX.php', // basename, used by re-install
'ignore' => ['/.git', '*.log', '/temp', '/uploads'],
'protect' => ['/uploads', '/temp'], // never deleted
'checksum' => false, // like rsync -c
'allowDelete' => false, // delete extras without --delete
'testMode' => false, // preview by default, run with --run
'compress' => true, // GZ during transfer
'compressSkipExt' => ['jpg','png','zip','gz','pdf','mp4'],
];
Loading please wait ...
Before you can download the PHP files, the dependencies should be resolved. This can take some minutes. Please be patient.