Skip to content

Commit

Permalink
Added a 'minimal server' example.
Browse files Browse the repository at this point in the history
  • Loading branch information
evert committed Oct 20, 2015
1 parent e09b67f commit d481121
Showing 1 changed file with 20 additions and 0 deletions.
20 changes: 20 additions & 0 deletions examples/minimal.php
@@ -0,0 +1,20 @@
<?php

/**
* This example shows the smallest possible sabre/dav server.
*/
include 'vendor/autoload.php';

$server = new Sabre\DAV\Server([
new Sabre\DAV\FS\Directory(__DIR__)
]);

/**
* Ok. Perhaps not the smallest possible. The browser plugin is 100% optional,
* but it really helps understanding the server.
*/
$server->addPlugin(
new Sabre\DAV\Browser\Plugin()
);

$server->exec();

0 comments on commit d481121

Please sign in to comment.