From db48e3f5d3a7dfaeb19e9e87b9d6a8f6effe11dc Mon Sep 17 00:00:00 2001 From: teepe Date: Fri, 25 Jan 2002 16:40:41 +0000 Subject: [PATCH] fixed 'list all' in addressbook #506624, thanks to Kurt Yoder git-svn-id: https://svn.code.sf.net/p/squirrelmail/code/trunk/squirrelmail@2237 7612ce4b-ef26-0410-bec9-ea0150e637f0 --- src/addrbook_search.php | 7 +++++-- src/addrbook_search_html.php | 5 ++++- 2 files changed, 9 insertions(+), 3 deletions(-) diff --git a/src/addrbook_search.php b/src/addrbook_search.php index 5cb11ff1..fca02aff 100644 --- a/src/addrbook_search.php +++ b/src/addrbook_search.php @@ -197,7 +197,7 @@ if ($show == 'form') { } else { /* Show personal addressbook */ - if ($show == 'blank' || !empty($listall)) { + if ($show == 'blank' && empty($listall)) { if($backend != -1 || $show == 'blank') { if ($show == 'blank') { @@ -221,9 +221,12 @@ if ($show == 'form') { } } else { + if( !empty( $listall ) ){ + $query = '*'; + } /* Do the search */ - if (!empty($query) && empty($listall)) { + if (!empty($query)) { if($backend == -1) { $res = $abook->s_search($query); diff --git a/src/addrbook_search_html.php b/src/addrbook_search_html.php index aac99716..778c52e2 100644 --- a/src/addrbook_search_html.php +++ b/src/addrbook_search_html.php @@ -185,10 +185,13 @@ if ($addrquery == '' || !empty($listall)) { } exit; + if ( !empty( $listall ) ){ + $addrquery = '*'; + } } else { /* Do the search */ - if (!empty($addrquery) && empty($listall)) { + if (!empty($addrquery)) { if ($backend == -1) { $res = $abook->s_search($addrquery); -- 2.25.1