/** * @brief transform a vcard into a ldap entry * @param VCard $vcard * @return array|false */ public function VCardToLdap($vcard) { $ldifReturn = array(); // Array to return foreach ($vcard->children() as $property) { // Basically, a $property can be converted into one or multiple ldif entries // and also some vcard properties can have data that can be split to fill different ldif entries $ldifArray = self::getLdifProperty($property); if (count($ldifArray) > 0) { self::updateLdifProperty($ldifReturn, $ldifArray); } } self::validateLdapEntry($ldifReturn); return $ldifReturn; }