public $error = false;
function __construct($server, $user, $pass, $db, $install = false) {
- global $a;
+ $a = get_app();
$stamp1 = microtime(true);
}
public function q($sql, $onlyquery = false) {
- global $a;
+ $a = get_app();
if (!$this->db || !$this->connected) {
return false;