[Tickets #1854] NEW: Compose Address-Book blank search patch

bugs at bugs.horde.org bugs at bugs.horde.org
Sat Apr 23 12:47:19 PDT 2005


DO NOT REPLY TO THIS MESSAGE. THIS EMAIL ADDRESS IS NOT MONITORED.

Ticket URL: http://bugs.horde.org/ticket/?id=1854
-----------------------------------------------------------------------
 Ticket             | 1854
 Created By         | kevin_myer at iu13.org
 Summary            | Compose Address-Book blank search patch
 Queue              | IMP
 Version            | 4.0.3
 State              | Unconfirmed
 Priority           | 1. Low
 Type               | Bug
 Owners             | 
+New Attachment     | imp-blank-contacts-search.patch
-----------------------------------------------------------------------


kevin_myer at iu13.org (2005-04-23 12:47) wrote:

Hello,

This simple patch allows a user to search and return all results from an
addressbook, while honoring a default setting of 'display_contacts'=0 for
the initial invocation of contacts.php.

As its worded, the 'display_contacts" preference controls whether an initial
search is done when a user invokes contacts.php from the compose window.  It
is stated that you might want to disable and lock this, if you have large
addressbooks (which we do and which we had done).  This reduces creating
unecessary load on our LDAP server.

However, if someone does want to search through all entries (maybe they want
to compose a message with a lot of recipients and prefer to choose the
receipients all from one list, instead of doing a search to find each
recipient), they can't do it, because the current contacts.php logic is such
that if they do a search for a blank entry, $search is null and we have
locked 'display_contacts" to disable it and this prevents the search call
from ever being executed.

What I did is simply to modify the formname value and set it to contacts. 
The first time, contacts.php is called, formname is compose, so a blank
search will not be permitted unless display_contacts is set to 1.  However,
if at this point, a user decides to do a search with no values, formname is
now set to contacts, and the user is able to search for and return all
entries.

This is an important feature for us, because our legacy email application,
which we are migrating from, displayed all users by default, in its
addressbook.  So our users are accustomed to selecting addresses from a
list.  Our goal is to have them use Expand Names, or tab auto-expansion, but
for backwards compatibility, we do need to have a way to display all
addresses.  We don't want to do that by default, for load purposes on the
LDAP server, but we do want to make it available, to help ease migration
anxieties.

 




More information about the bugs mailing list