In partial answer to my own question, it seems you cannot autocomplete from a localsql address book if you lock your search sources. Does this sound correct? Sounds like a bug to me.

Setting 'locked' to false on both $_prefs['search_sources'] and $_prefs['search_fields'] allows one to choose the local personal address book and the fields associated with it.

In addition fields uses when expanding addresses MUST be specified in the turba sources.php file within the map and search sections. (I guess this should have been obvious, but wasn't for me, perhaps it should be included in the comment above the $_prefs['search_fields'] section.

On Jul 10, 2008, at 4:27 PM, Elliot Anders wrote:

I have three address books successfully working simultaneously in Turba, but Imp only sees the first one listed in the sources.php file. Is there a setting other than those below I need to enable to get Imp's autocomplete feature to see the other two address books? Re-arranging the Turba sources.php file does actually affect the imp autocomplete, but only one source ever works at any given time.

I'm using Horde Webmail 1.1, below is the relevant section of Imp's prefs.php:

// address book(s) to use when expanding addresses
// You can provide default values this way (note the \t and the double quotes):
// 'value' => "source_one\tsource_two"
// refer to turba/config/sources.php for possible source values
$_prefs['search_sources'] = array(
   'value' => "marlboroldap\tlocalsql\tfavorites",
   'locked' => true,
   'shared' => false,
   'type' => 'implicit');

// field(s) to use when expanding addresses
// This depends on the search_sources preference if you want to provide
// default values:
// 'value' => "source_one\tfield_one\tfield_two\nsource_two \tfield_three" // will search the fields 'field_one' and 'field_two' in source_one and
// 'field_three' in source_two.
// refer to turba/config/sources.php for possible source and field values
$_prefs['search_fields'] = array(
'value' => "localsql\tname\temail\nmarlboroldap\tname\temail \nfavorites\tname\temail",
   'locked' => true,
   'shared' => false,
   'type' => 'implicit');

// address book to use for adding addresses
// put $cfgSources array element name in the value field.
// Setting value to localsql would allow you to add contacts to MySQL database
// See turba/config/sources.php for more info
$_prefs['add_source'] = array(
   'value' => 'localsql',
   'locked' => true,
   'shared' => false,
   'type' => 'implicit'
);


Thanks for any insight,
Elliot
--
IMP mailing list - Join the hunt: http://horde.org/bounties/#imp
Frequently Asked Questions: http://horde.org/faq/
To unsubscribe, mail: [EMAIL PROTECTED]

--
IMP mailing list - Join the hunt: http://horde.org/bounties/#imp
Frequently Asked Questions: http://horde.org/faq/
To unsubscribe, mail: [EMAIL PROTECTED]

Reply via email to