$rcmail_config['address_book_type'] = 'ldap';$rcmail_config['ldap_public']['addressbook'] = array( ... 'LDAP_Object_Classes' => array('inetOrgPerson'), 'required_fields' => array('cn', 'sn', 'mail'), 'LDAP_rdn' => 'cn', 'search_fields' => array('mail', 'cn'), ... 'filter' => '(objectClass=inetOrgPerson)', ...);$config['autocomplete_addressbooks'] = array('addressbook');// 1 - Ask if sender is not in address book !$config['show_images'] = 1;
slapd[]: ADD dn="cn=instagram,ou=addressbook,dc=example,dc=com"slapd[]: RESULT err=0
slapd[]: SRCH base="ou=addressbook,dc=example,dc=com" scope=2 deref=0 filter="(&(objectClass=inetOrgPerson)(|(cn=no-reply@mail.instagram.com)))"slapd[]: SEARCH RESULT err=0 nentries=0
How do you map ldap attributes to addressbook fields (fieldmap)?
'search_fields' => array('mail', 'cn'), 'name_field' => 'cn', 'email_field' => 'mail', 'surname_field' => 'sn', 'firstname_field' => 'givenName', 'fieldmap' => array( 'name' => 'cn', 'surname' => 'sn', 'middlename' => 'initials', 'firstname' => 'givenName', 'jobtitle' => 'title', 'department' => 'departmentNumber', 'email' => 'mail', 'phone:work' => 'telephoneNumber', 'phone:mobile' => 'mobile', 'street' => 'street', 'zipcode' => 'postalCode', 'locality' => 'l', 'organization' => 'o', 'notes' => 'description', 'website' => 'labeledURI', 'photo' => 'jpegPhoto', ),
[Europe/Moscow] PHP Warning: array_walk() expects parameter 1 to be array, string given in /pach to/program/lib/Roundcube/rcube_ldap.php on line 844
else { // map address book fields into ldap attributes $attributes = array(); foreach ((array) $fields as $field) { if ($this->coltypes[$field] && ($attrs = $this->coltypes[$field]['attributes'])) { $attributes = array_merge($attributes, (array) $attrs); } } }