//
function set_sql($sql)
{
+ global $SysPrefs;
+
if ($sql != $this->sql) {
$this->sql = $sql;
$this->ready = false;
$this->select = $parts[0];
$sql = $parts[1];
} else {
- if ($go_debug)
+ if ($SysPrefs->go_debug)
display_error("Invalid sql input for db_pager");
}
//
function _init()
{
- global $go_debug;
+ global $SysPrefs;
if ($this->ready == false ) {
$sql = $this->_sql_gen(true);
$this->max_page = $this->page_len ?
ceil($this->rec_count/$this->page_len) : 0;
- if ($go_debug) { // FIX - need column name parsing, but for now:
+ if ($SysPrefs->go_debug) { // FIX - need column name parsing, but for now:
// check if field names are set explicite in col def
// for all initially ordered columns
foreach ($this->columns as $col) {
if (isset($_SESSION[$name]))
$_SESSION[$name]->ready = false;
}
-?>