Implementing a WebDAV filesystem with PHP and SabreDAV
Downloading and Installing SabreDAV
Now that you have a virtual host dedicated to your WebDAV server, we can download and install SabreDAV. At time of writing, the current version of SabreDAV is 1.0.10. You can download it from http://code.google.com/p/sabredav/downloads/list.
Once downloaded, extract it and move the contents of
lib to the
/var/www/dav/include directory. You should then have the following files present:
To load the SabreDAV library, we simple need to include the
Sabre.autoload.php file. This will register a new auto-loader in PHP that will load required classes on demand.
Sabre.includes.phpfile instead to load every file. If your auto-loader uses PEAR class-naming, then that will also work (e.g. Foo/Bar/Baz.php corresponds to Foo_Bar_Baz) and you don't need to load any SabreDAV files ahead of time.