[imp] add_source preference value
Vilius Šumskas
vilius at lnk.lt
Thu Jul 28 08:30:28 UTC 2011
> Zitat von Vilius ?umskas <vilius at lnk.lt>:
>
> > Hello,
> >
> > add_source preference description reads:
> >
> > // 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
> >
> > However with H4 this doesn't work anymore. I get "Unknown address
> > book 'localsql'." every time I send an email. Also, when I re-save
> > preferences trough GUI and look at MySQL database I see that the new
> > add_source preference value goes like "NAkkIDxJBD9OMCV5CTiyKsA".
> > What is the correct corresponding value for this preference under H4
> > so I can put it to prefs.local.php for all new users?
>
> See the example hook.
OK. I have enabled prefs_init hook in imp/config/hooks.php
I have created imp/config/prefs.local.php with a content:
$_prefs['add_source'] = array(
'value' => '',
'type' => 'enum',
'enum' => array(),
'hook' => true,
'desc' => _("Choose the address book to use when adding addresses.")
);
I still get the same message about unknown address book 'localsql' when sending email. Seems like $GLOBALS['registry']->call('contacts/getDefaultShare'); returns 'localsql' instead of share id.
Maybe getDefaultShare needs to be changed into something?
--
Vilius
More information about the imp
mailing list