exit; } // check if server supports webdav rfc 2518 if (!$wdc->check_webdav()) { print 'Error: server does not support webdav or user/password may be wrong'; exit; } $dir = $wdc->ls('/'); ?> <h1>class_webdav_client Test-Suite:</h1><p> Using method webdav_client::ls to get a listing of dir /:<br> <table summary="ls" border="1"> <th>Filename</th><th>Size</th><th>Creationdate</th><th>Resource Type</th><th>Content Type</th><th>Activelock Depth</th><th>Activelock Owner</th><th>Activelock Token</th><th>Activelock Type</th> <?php foreach ($dir as $e) { $ts = $wdc->iso8601totime($e['creationdate']); $line = sprintf('<tr><td>%s </td><td>%s </td><td>%s </td><td>%s </td><td>%s </td><td>%s </td><td>%s </td><td>%s </td><td>%s </td></tr>', $e['href'], $e['getcontentlength'], date('d.m.Y H:i:s', $ts), $e['resourcetype'], $e['getcontenttype'], $e['activelock_depth'], $e['activelock_owner'], $e['activelock_token'], $e['activelock_type']); print urldecode($line); } ?> </table> <p> Create a new collection (Directory) using method webdav_client::mkcol... <?php $test_folder = '/wdc test 1 folder'; print '<br>creating collection ' . $test_folder . ' ...<br>'; $http_status = $wdc->mkcol($test_folder); print 'webdav server returns ' . $http_status . '<br>'; print 'removing collection just created using method webdav_client::delete ...<br>'; $http_status_array = $wdc->delete($test_folder); print 'webdav server returns ' . $http_status_array['status'] . '<br>';