From 6b56c9927535d857f0a9cb9f9bee2dfa0e47432d Mon Sep 17 00:00:00 2001 From: Jan Schneider Date: Wed, 30 Dec 2009 15:14:40 +0100 Subject: [PATCH] Re-add lost hooks file. Still need to fix where the hooks are called. --- turba/config/hooks.php.dist | 86 +++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 86 insertions(+) create mode 100644 turba/config/hooks.php.dist diff --git a/turba/config/hooks.php.dist b/turba/config/hooks.php.dist new file mode 100644 index 000000000..7cb0cf6a9 --- /dev/null +++ b/turba/config/hooks.php.dist @@ -0,0 +1,86 @@ + $share) { +// $params = @unserialize($share->get('params')); +// if (empty($params['source'])) { +// continue; +// } +// $driver = &Turba_Driver::factory($params['source'], $cfgSources[$params['source']]); +// if (is_a($driver, 'PEAR_Error')) { +// continue; +// } +// if ($driver->checkDefaultShare($share, $cfgSources[$params['source']])) { +// return $uid; +// } +// } +// } +// } + + /** + * Called when we store a value. + * + * Passwords should be MD5 encoded, but not displayed. + * + * @todo Make this a generic encode() method. + */ +// public function encode_password($new_password, $old_password, &$contact) +// { +// if (is_null($new_password) || $new_password == '' || +// $new_password == '[Not Displayed]') { +// return $old_password; +// } else { +// return md5($new_password); +// } +// } + + /** + * Called when we display a value. + * + * Passwords should be MD5 encoded, but not displayed. + * + * @todo Make this a generic decode() method. + */ +// public function decode_password($password, &$contact) +// { +// if (strstr($_SERVER['PHP_SELF'], 'editobject')) { +// return null; +// } else { +// return '[Not Displayed]'; +// } +// } +} -- 2.11.0