Created
May 4, 2015 13:23
-
-
Save LukasReschke/4542cb7f828a72607683 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
require_once('./lib/base.php'); | |
use Sabre\DAV\Client; | |
$settings = [ | |
'baseUri' => 'http://localhost/master/remote.php/webdav/', | |
'userName' => 'admin', | |
'password' => 'admin', | |
'proxy' => 'localhost:8080', | |
]; | |
$client = new Client($settings); | |
// Example: PROPFIND files | |
var_dump($client->propfind('', [], 1)); | |
// Example: Move welcome.txt to bye.txt | |
$client->request('MOVE', $settings['baseUri'].'/welcome.txt', null, ['Destination' => $settings['baseUri'].'/bye.txt']); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment