diff --git a/phpgwapi/inc/class.db.inc.php b/phpgwapi/inc/class.db.inc.php index 9c83bef6c4..67991fa761 100644 --- a/phpgwapi/inc/class.db.inc.php +++ b/phpgwapi/inc/class.db.inc.php @@ -14,11 +14,7 @@ /* $Id$ */ - if (empty($GLOBALS['phpgw_info']['server']['db_type'])) - { - $GLOBALS['phpgw_info']['server']['db_type'] = 'mysql'; - } - include(PHPGW_API_INC.'/class.db_'.$GLOBALS['phpgw_info']['server']['db_type'].'.inc.php'); + /* db_type setup moved after the class below - milosch */ /** * Database abstraction library @@ -246,7 +242,7 @@ */ function transaction_begin() { - return True; + return True; } /** @@ -256,7 +252,7 @@ */ function transaction_commit() { - return True; + return True; } /** @@ -266,7 +262,7 @@ */ function transaction_abort() { - return True; + return True; } /** @@ -297,7 +293,6 @@ function unlock() {} - /** * Get the number of rows affected by last update * @@ -462,7 +457,7 @@ */ function index_names() { - return array(); + return array(); } /** @@ -552,4 +547,10 @@ return $table ? $this->table_definitions[$app][$table] : $this->table_definitions[$app]; } } + + if(empty($GLOBALS['phpgw_info']['server']['db_type'])) + { + $GLOBALS['phpgw_info']['server']['db_type'] = 'mysql'; + } + include(PHPGW_API_INC.'/class.db_'.$GLOBALS['phpgw_info']['server']['db_type'].'.inc.php'); ?> diff --git a/phpgwapi/inc/class.sessions.inc.php b/phpgwapi/inc/class.sessions.inc.php index 45facca03f..4b4217d75e 100644 --- a/phpgwapi/inc/class.sessions.inc.php +++ b/phpgwapi/inc/class.sessions.inc.php @@ -5,7 +5,7 @@ * and Joseph Engo * * and Ralf Becker * * Copyright (C) 2000, 2001 Dan Kuykendall * - * Parts Copyright (C) 2003 Free Software Foundation Inc * + * Parts Copyright (C) 2003 Free Software Foundation Inc * * -------------------------------------------------------------------------* * This library is part of the phpGroupWare API * * http://www.phpgroupware.org/api * @@ -25,11 +25,7 @@ /* $Id$ */ - if (empty($GLOBALS['phpgw_info']['server']['sessions_type'])) - { - $GLOBALS['phpgw_info']['server']['sessions_type'] = 'db'; - } - include_once(PHPGW_API_INC.'/class.sessions_'.$GLOBALS['phpgw_info']['server']['sessions_type'].'.inc.php'); + /* sessions_type setup moved after the class below - milosch */ /** * Session Management Libabray @@ -1212,8 +1208,8 @@ {} /** - * Remove stale sessions out of the database - */ + * Remove stale sessions out of the database + */ function clean_sessions() {} @@ -1301,3 +1297,10 @@ function total() {} } + + if(empty($GLOBALS['phpgw_info']['server']['sessions_type'])) + { + $GLOBALS['phpgw_info']['server']['sessions_type'] = 'db'; + } + include_once(PHPGW_API_INC.'/class.sessions_'.$GLOBALS['phpgw_info']['server']['sessions_type'].'.inc.php'); +