Skip to content

Exception: Could'n find a CalDAV-collection under the url when connecting to EGroupWare #40

Description

@Apps-n-Add-Ons

There is a bug (or, rather, an enhancement needed) in CalDAVClient.php

When connecting to EGroupWare, you get the error:
Exception: Could'n find a CalDAV-collection under the url

It is an easy fix.

The problem is that EGW sends header of "Dav:" not "DAV:" as in this code.

Change around line 168 from
$dav_header = preg_grep('/^DAV:/', $headers);
to
$dav_header = preg_grep('/^DAV:/i', $headers);

and around line 171 from
$dav_header = preg_replace('/^DAV: /', '', $dav_header);
to
$dav_header = preg_replace('/^DAV: /i', '', $dav_header);

(allow upper/lower case on the preg_ functions)

After that, you get data from EGW!

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions