alecpl
2010-07-30 e6ce0062f2331b8756cc91944ceaea8d7cbffd18
program/steps/addressbook/copy.inc
@@ -27,7 +27,7 @@
$target = get_input_value('_to', RCUBE_INPUT_POST);
$target_group = get_input_value('_togid', RCUBE_INPUT_POST);
if ($cid && preg_match('/^[a-z0-9\-_=]+(,[a-z0-9\-_=]+)*$/i', $cid) && strlen($target) && $target !== $source)
if ($cid && preg_match('/^[a-zA-Z0-9\+\/=_-]+(,[a-zA-Z0-9\+\/=_-]+)*$/', $cid) && strlen($target) && $target !== $source)
{
  $success = 0;
  $TARGET = $RCMAIL->get_address_book($target);
@@ -37,7 +37,7 @@
    $ids = array();
    foreach ($arr_cids as $cid) {
      $plugin = $RCMAIL->plugins->exec_hook('create_contact', array(
      $plugin = $RCMAIL->plugins->exec_hook('contact_create', array(
        'record' => $CONTACTS->get_record($cid, true),
        'source' => $target,
        'group' => $target_group,
@@ -91,4 +91,3 @@
// send response
$OUTPUT->send();
?>