From c54312150c003b1d2cd67ad300bed0032b8dfaba Mon Sep 17 00:00:00 2001 From: Andrew McMillan Date: Fri, 9 Oct 2009 07:54:19 -0700 Subject: [PATCH] Basic (but broken & untested) support for webdav sync. DB changes to come. --- inc/caldav-REPORT.php | 17 ++++++++++++----- 1 file changed, 12 insertions(+), 5 deletions(-) diff --git a/inc/caldav-REPORT.php b/inc/caldav-REPORT.php index c9dc28db..40f04851 100644 --- a/inc/caldav-REPORT.php +++ b/inc/caldav-REPORT.php @@ -4,8 +4,8 @@ * * @package davical * @subpackage caldav -* @author Andrew McMillan -* @copyright Catalyst .Net Ltd +* @author Andrew McMillan +* @copyright Catalyst .Net Ltd, Morphoss Ltd * @license http://gnu.org/copyleft/gpl.html GNU GPL v2 */ dbg_error_log("REPORT", "method handler"); @@ -48,9 +48,16 @@ if ( $xmltree->GetTag() == "urn:ietf:params:xml:ns:caldav:free-busy-query" ) { } $reply = new XMLDocument( array( "DAV:" => "" ) ); -if ( $xmltree->GetTag() == "DAV::principal-property-search" ) { - include("caldav-REPORT-principal.php"); - exit; // Not that the above include should return anyway +switch( $xmltree->GetTag() ) { + case 'DAV::principal-property-search': + include("caldav-REPORT-principal.php"); + exit; // Not that it should return anyway. + case 'DAV::sync-collection': + include("caldav-REPORT-sync-collection.php"); + exit; // Not that it should return anyway. + case 'DAV::expand-property': + include("caldav-REPORT-expand-property.php"); + exit; // Not that it should return anyway. } // Must have read privilege for all other reports