function _dump_globals($ignore_vars = '', $no_uc_vars = false) { if (!fbDebug::debugging()) { return ''; } $g = $GLOBALS; static $skip_vars = '^argc$|^argv$|^ADODB_Database$|^ADODB_vers$|^conf$|^conn$|^sectioninfo$|^sessname$'; // if ($ignore_vars) { // $match = '/' . $ignore_vars . '|' . $skip_vars . '/'; // } else { $match = '/' . $skip_vars . '/'; // } $rv = fbDebug::hr(); $rv .= fbDebug::pre(sprintf("\n%d GLOBALS (less {$match}): \n", count($g))); ksort($g); reset($g); while (list($key, $val) = each($g)) { if (preg_match($match, $key)) { continue; } if ($no_uc_vars) { if (strtoupper($key) == $key) { continue; } } $rv .= fbDebug::_dump($val, $key); } $rv .= "\n"; $rv .= fbDebug::hr(); return $rv; }