8 require_once(
"header.inc.php");
9 require_once(CH_DIRECTORY_PATH_INC .
'utils.inc.php');
10 require_once(CH_DIRECTORY_PATH_CLASSES .
'ChWsbDb.php');
23 date_default_timezone_set(
getParam(
'site_timezone'));
31 return $GLOBALS[
'MySQL']->listTables();
39 function db_res($query, $bindings = [])
41 return $GLOBALS[
'MySQL']->res($query, $bindings);
58 return $GLOBALS[
'MySQL']->getAffectedRows($oStmt);
68 return $GLOBALS[
'MySQL']->getAll($query, $bindings);
76 function db_arr($query, $bindings = [])
78 return $GLOBALS[
'MySQL']->getRow($query, $bindings, PDO::FETCH_BOTH);
88 return $GLOBALS[
'MySQL']->getRow($query, $bindings);
98 function db_value($query, $bindings = [], $error_checking =
true, $index = 0)
100 return $GLOBALS[
'MySQL']->getOne($query, $bindings, $index);
111 return $GLOBALS[
'MySQL']->fillArray($res, PDO::FETCH_BOTH);
122 return $GLOBALS[
'MySQL']->fillArray($res, PDO::FETCH_ASSOC);
141 return $GLOBALS[
'MySQL']->getOne(
"SELECT `desc` FROM `sys_options` WHERE `Name` = ?", [
$sParamName]);