program/include/rcube_ldap.php | ●●●●● patch | view | raw | blame | history | |
program/steps/addressbook/save.inc | ●●●●● patch | view | raw | blame | history |
program/include/rcube_ldap.php
@@ -1019,7 +1019,7 @@ $dn = self::dn_encode($dn); // add new contact to the selected group if ($this->groups) if ($this->group_id) $this->add_to_group($this->group_id, $dn); return $dn; @@ -1700,13 +1700,16 @@ if (($group_cache = $this->cache->get('groups')) === null) $group_cache = $this->_fetch_groups(); if (!is_array($contact_ids)) $contact_ids = explode(',', $contact_ids); $base_dn = $this->groups_base_dn; $group_name = $group_cache[$group_id]['name']; $member_attr = $group_cache[$group_id]['member_attr']; $group_dn = "cn=$group_name,$base_dn"; $new_attrs = array(); foreach (explode(",", $contact_ids) as $id) foreach ($contact_ids as $id) $new_attrs[$member_attr][] = self::dn_decode($id); $this->_debug("C: Add [dn: $group_dn]: ".print_r($new_attrs, true)); program/steps/addressbook/save.inc
@@ -50,10 +50,12 @@ foreach ((array)$vals as $i => $val) $values[$i][$childcol] = $val; } $subtypes = get_input_value('_subtype_' . $col, RCUBE_INPUT_POST); foreach ($subtypes as $i => $subtype) $subtypes = isset($_REQUEST['_subtype_' . $col]) ? (array)get_input_value('_subtype_' . $col, RCUBE_INPUT_POST) : array(''); foreach ($subtypes as $i => $subtype) { $suffix = $subtype ? ':'.$subtype : ''; if ($values[$i]) $a_record[$col.':'.$subtype][] = $values[$i]; $a_record[$col.$suffix][] = $values[$i]; } } // assign values and subtypes else if (is_array($_POST[$fname])) {