From 341fd023b8370d2bdd74abb133505e6f14c110cb Mon Sep 17 00:00:00 2001 From: Miles Lott Date: Sun, 2 Sep 2001 00:26:16 +0000 Subject: [PATCH] now using GLOBALS --- phpgwapi/inc/class.db_pgsql.inc.php | 14 ++++---------- 1 file changed, 4 insertions(+), 10 deletions(-) diff --git a/phpgwapi/inc/class.db_pgsql.inc.php b/phpgwapi/inc/class.db_pgsql.inc.php index c914d92a79..05dd529106 100644 --- a/phpgwapi/inc/class.db_pgsql.inc.php +++ b/phpgwapi/inc/class.db_pgsql.inc.php @@ -145,17 +145,15 @@ function limit($start) { - global $phpgw_info; - echo 'Warning: limit() is no longer used, use limit_query()'; if ($start == 0) { - $s = 'limit ' . $phpgw_info['user']['preferences']['common']['maxmatchs']; + $s = 'limit ' . $GLOBALS['phpgw_info']['user']['preferences']['common']['maxmatchs']; } else { - $s = 'limit ' . $phpgw_info['user']['preferences']['common']['maxmatchs'] . ',' . $start; + $s = 'limit ' . $GLOBALS['phpgw_info']['user']['preferences']['common']['maxmatchs'] . ',' . $start; } return $s; } @@ -199,11 +197,9 @@ /* public: perform a query with limited result set */ function limit_query($Query_String, $offset, $line = '', $file = '', $num_rows = '') { - global $phpgw_info; - if (! $num_rows) { - $num_rows = $phpgw_info['user']['preferences']['common']['maxmatchs']; + $num_rows = $GLOBALS['phpgw_info']['user']['preferences']['common']['maxmatchs']; } if ($offset == 0) @@ -449,8 +445,6 @@ function halt($msg, $line = "", $file = "") { - global $phpgw; - if($this->Halt_On_Error == "no") { return; @@ -474,7 +468,7 @@ if ($this->Halt_On_Error == 'yes') { echo '

Session halted.'; - $phpgw->common->phpgw_exit(True); + $GLOBALS['phpgw']->common->phpgw_exit(True); } }