Function to convert a Horde_Icalendar_Vcard object into a Turba
Object Hash with Turba attributes suitable as a parameter for add().
protected function toHash($vcard, $map = array()) { $driver = new Turba_Driver(); foreach ($map as $field => $config) { $driver->map[$field] = $config; } $ical = new Horde_Icalendar(); $ical->parsevCalendar($vcard); return $driver->toHash($ical->getComponent(0)); }