summaryrefslogtreecommitdiff
path: root/list.php
diff options
context:
space:
mode:
authorLester Caine <lester@lsces.co.uk>2026-06-02 15:02:38 +0100
committerLester Caine <lester@lsces.co.uk>2026-06-02 15:02:38 +0100
commite88544380267e3539fd28a6cefea844fb75e684a (patch)
treef5a6f7be7307e935e8d51f1594b62af5d209e846 /list.php
parent3e8fc0c354098cdc615401d7d0d04cf5225035d3 (diff)
downloadcontact-e88544380267e3539fd28a6cefea844fb75e684a.tar.gz
contact-e88544380267e3539fd28a6cefea844fb75e684a.tar.bz2
contact-e88544380267e3539fd28a6cefea844fb75e684a.zip
Rename list.php → list_contacts.php; add odd/even row pairs to list
list_contacts.php: modern replacement with clean code, no dead session logic, referencing list.tpl. list.php: now a thin redirect for backward compatibility. list.tpl: alternate odd/even class on each contact's row pair. All internal references (display_contact, index, load_emails, menu, admin_xref_types) updated to list_contacts.php. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Diffstat (limited to 'list.php')
-rwxr-xr-xlist.php49
1 files changed, 2 insertions, 47 deletions
diff --git a/list.php b/list.php
index 16b0955..89bf5a1 100755
--- a/list.php
+++ b/list.php
@@ -1,55 +1,10 @@
<?php
/**
- * @version $Header: /cvsroot/bitweaver/_bit_contact/list.php,v 1.5 2010/02/08 21:27:22 wjames5 Exp $
- *
- * Copyright (c) 2006 bitweaver.org
- * All Rights Reserved. See below for details and a complete list of authors.
- * Licensed under the GNU LESSER GENERAL PUBLIC LICENSE. See http://www.gnu.org/copyleft/lesser.html for details
- *
* @package contact
* @subpackage functions
*/
-/**
- * required setup
- */
require_once '../kernel/includes/setup_inc.php';
-use Bitweaver\Contact\Contact;
-use Bitweaver\KernelTools;
-
-$gBitSystem->verifyPackage( 'contact' );
-$gBitSystem->verifyPermission( 'p_contact_view' );
-
-$gContent = new Contact( );
-$gContent->invokeServices( 'content_list_function', $_REQUEST );
-
-// Handle the request hash storing into the session.
-$gContent->mTypes->processRequestHash($_REQUEST, $_SESSION['contact']);
-
-$listHash = $_REQUEST;
-/*
- * Setup which contact types we want to view.
-$contactTypes = $gContent->getContactTypes();
-if( $gBitUser->hasPermission("p_contact_view_changes") && $_SESSION['contact']['contact_type_guid'] ) {
- $listHash['contact_type_guid'] = $_SESSION['contact']['contact_type_guid'];
-} else {
- foreach ($contactTypes as $key => $val) {
- if ($gBitSystem->isFeatureActive('contact_default_'.$key)) {
- $listHash['contact_type_guid'][] = $key;
- }
- }
-} */
-// Get a list of matching contact entries
-$listcontacts = $gContent->getList( $listHash );
-
-if ( $listHash['listInfo']['count'] == 1 ){
- KernelTools::bit_redirect( CONTACT_PKG_URL."display_contact.php?content_id=".$listcontacts[0]['content_id'] );
-}
-
-$gBitSmarty->assign( 'listcontacts', $listcontacts );
-$gBitSmarty->assign( 'listInfo', $listHash['listInfo'] );
-
-$gBitSystem->setBrowserTitle("View Contacts List");
-// Display the template
-$gBitSystem->display( 'bitpackage:contact/list.tpl', NULL, [ 'display_mode' => 'list' ]);
+header( 'Location: ' . CONTACT_PKG_URL . 'list_contacts.php?' . http_build_query( $_GET ) );
+die;