summaryrefslogtreecommitdiff
path: root/edit.php
diff options
context:
space:
mode:
authorLester Caine <lester@lsces.co.uk>2026-06-06 11:22:49 +0100
committerLester Caine <lester@lsces.co.uk>2026-06-06 11:22:49 +0100
commit2efbb78b7ceff6c369c2bee68c2a09270ce0fcde (patch)
tree2d9f7778e23c5174d75264b343aa0116d1d2cc90 /edit.php
parenteb77765b4dd1e41f1365a53289d80408d112b491 (diff)
downloadcontact-2efbb78b7ceff6c369c2bee68c2a09270ce0fcde.tar.gz
contact-2efbb78b7ceff6c369c2bee68c2a09270ce0fcde.tar.bz2
contact-2efbb78b7ceff6c369c2bee68c2a09270ce0fcde.zip
edit.php: add expunge=1 handler; contact_date_bar: use edit.php?expunge=1
Replaces broken remove_contact.php link with edit.php?expunge=1 pattern, consistent with other edit pages. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Diffstat (limited to 'edit.php')
-rwxr-xr-xedit.php6
1 files changed, 5 insertions, 1 deletions
diff --git a/edit.php b/edit.php
index 1320f5f..6bea6aa 100755
--- a/edit.php
+++ b/edit.php
@@ -49,7 +49,11 @@ if (isset( $_REQUEST["preview"] )) {
}
// Pro
-if (isset($_REQUEST["fCancel"])) {
+if( !empty( $_REQUEST['expunge'] ) && $gContent->isValid() ) {
+ $gBitSystem->verifyPermission( 'p_contact_expunge' );
+ $gContent->expunge();
+ KernelTools::bit_redirect( CONTACT_PKG_URL . 'list_contacts.php' );
+} elseif (isset($_REQUEST["fCancel"])) {
if( !empty( $gContent->mContentId ) ) {
KernelTools::bit_redirect( $gContent->getDisplayUrl() );
} else {