X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=mod%2Fcontacts.php;h=a405cedbc6329b6d80cf937a8788b0b67c39d9c7;hb=a2cef94d8b637cc449498aac4108c336e0f7c442;hp=8a36fa4cb6ced11b63946b00bd81a4f5e0193eaf;hpb=63d02d98c5ea1767e3cfa20b1dec0cd5ab069bc0;p=friendica.git diff --git a/mod/contacts.php b/mod/contacts.php index 8a36fa4cb6..a405cedbc6 100644 --- a/mod/contacts.php +++ b/mod/contacts.php @@ -2,6 +2,7 @@ require_once('include/Contact.php'); require_once('include/socgraph.php'); +require_once('include/contact_selectors.php'); function contacts_init(&$a) { if(! local_user()) @@ -33,7 +34,7 @@ function contacts_init(&$a) { '$photo' => $a->data['contact']['photo'] )); $follow_widget = ''; - } + } else { $vcard_widget = ''; $follow_widget = follow_widget(); @@ -211,6 +212,9 @@ function contacts_content(&$a) { intval($contact_id), intval(local_user()) ); + if ($archived) { + q("UPDATE `item` SET `private` = 2 WHERE `contact-id` = %d AND `uid` = %d", intval($contact_id), intval(local_user())); + } if($r) { //notice( t('Contact has been ') . (($archived) ? t('archived') : t('unarchived')) . EOL ); info( (($archived) ? t('Contact has been archived') : t('Contact has been unarchived')) . EOL ); @@ -221,6 +225,36 @@ function contacts_content(&$a) { if($cmd === 'drop') { + // Check if we should do HTML-based delete confirmation + if($_REQUEST['confirm']) { + //