summaryrefslogtreecommitdiff
path: root/plugins/kolab_addressbook
diff options
context:
space:
mode:
authorthomasb <thomasb@208e9e7b-5314-0410-a742-e7e81cd9613c>2010-11-22 10:18:46 +0000
committerthomasb <thomasb@208e9e7b-5314-0410-a742-e7e81cd9613c>2010-11-22 10:18:46 +0000
commit494504d537c1ec61291aa2f9155cca3476f473df (patch)
tree757710053f1dcdf07721f53be9dc1514637e7096 /plugins/kolab_addressbook
parentd23e3a598e7844ef75752dfc4decf9c3650a0fff (diff)
Move core Kolab functions to a separate plugin to be used by others too
git-svn-id: https://svn.roundcube.net/trunk@4247 208e9e7b-5314-0410-a742-e7e81cd9613c
Diffstat (limited to 'plugins/kolab_addressbook')
-rw-r--r--plugins/kolab_addressbook/config.inc.php.dist8
-rw-r--r--plugins/kolab_addressbook/kolab_addressbook.php14
2 files changed, 4 insertions, 18 deletions
diff --git a/plugins/kolab_addressbook/config.inc.php.dist b/plugins/kolab_addressbook/config.inc.php.dist
deleted file mode 100644
index b6ac25a4d..000000000
--- a/plugins/kolab_addressbook/config.inc.php.dist
+++ /dev/null
@@ -1,8 +0,0 @@
-<?php
-
-// Sample configuration for Kolab LDAP binding used by Kolab_Storage
-$rcmail_config['kolab']['ldap']['basedn'] = 'dc=kolabserver,dc=local';
-$rcmail_config['kolab']['ldap']['phpdn'] = 'cn=nobody,cn=internal,dc=kolabserver,dc=local';
-$rcmail_config['kolab']['ldap']['phppw'] = '<ldap-pwd-goes-here>';
-
-?>
diff --git a/plugins/kolab_addressbook/kolab_addressbook.php b/plugins/kolab_addressbook/kolab_addressbook.php
index 4c5a84e5f..807dfb8ec 100644
--- a/plugins/kolab_addressbook/kolab_addressbook.php
+++ b/plugins/kolab_addressbook/kolab_addressbook.php
@@ -6,10 +6,7 @@ require_once(dirname(__FILE__) . '/rcube_kolab_contacts.php');
* Kolab address book
*
* Sample plugin to add a new address book source with data from Kolab storage
- *
* This is work-in-progress for the Roundcube+Kolab integration.
- * The library part is to be moved into a separate PEAR package or plugin
- * that this and other Kolab-related plugins will depend on.
*
* @author Thomas Bruederli <roundcube@gmail.com>
*
@@ -24,17 +21,14 @@ class kolab_addressbook extends rcube_plugin
*/
public function init()
{
- // load local config
- $this->load_config();
+ // load required plugin
+ $this->require_plugin('kolab_core');
+ // register hooks
$this->add_hook('addressbooks_list', array($this, 'address_sources'));
$this->add_hook('addressbook_get', array($this, 'get_address_book'));
$this->add_hook('contact_form', array($this, 'contact_form'));
-
- // extend include path to load bundled Horde classes
- $include_path = $this->home . '/lib' . PATH_SEPARATOR . ini_get('include_path');
- set_include_path($include_path);
-
+
// extend list of address sources to be used for autocompletion
$rcmail = rcmail::get_instance();
if ($rcmail->action == 'autocomplete' || $rcmail->action == 'group-expand') {