PHP code example of ngmy / l4-dav

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

    

ngmy / l4-dav example snippets


'Ngmy\L4Dav\L4DavServiceProvider',

'L4Dav' => 'Ngmy\L4Dav\Facades\L4Dav',

L4Dav::get('path/to/remote/file', '/path/to/local/file');

L4Dav::put('/path/to/local/file', 'path/to/remote/file');

L4Dav::delete('path/to/remote/file');

L4Dav::copy('path/to/source/file', 'path/to/dest/file');

L4Dav::move('path/to/source/file', 'path/to/dest/file');

L4Dav::mkdir('path/to/remote/directory/');

L4Dav::exists('path/to/remote/directory/');

L4Dav::ls('path/to/remote/directory/');

$response = L4Dav::put('/path/to/local/file', 'path/to/remote/file');
$response->getStatus();

$response = L4Dav::put('/path/to/local/file', 'path/to/remote/file');
$response->getMessage();

$response = L4Dav::put('/path/to/local/file', 'path/to/remote/file');
$response->getBody();

php artisan config:publish ngmy/l4-dav