mirror of
https://github.com/dg/dibi.git
synced 2025-07-17 04:21:17 +02:00
* throwing exception in DibiTranslator and DibiDriver
+ added dibi::$errorMode
This commit is contained in:
@@ -3,7 +3,7 @@ Copyright notice
|
|||||||
|
|
||||||
dibi (C) David Grudl, 2005-2006 <dave@dgx.cz>
|
dibi (C) David Grudl, 2005-2006 <dave@dgx.cz>
|
||||||
|
|
||||||
For more information, visit the homepage http://texy.info/dibi
|
For more information, visit the homepage http://dibi.texy.info/
|
||||||
or author's weblog: http://www.dgx.cz/trine/
|
or author's weblog: http://www.dgx.cz/trine/
|
||||||
|
|
||||||
This program is free software; you can redistribute it and/or modify
|
This program is free software; you can redistribute it and/or modify
|
||||||
|
File diff suppressed because one or more lines are too long
@@ -9,16 +9,16 @@
|
|||||||
* This source file is subject to the GNU GPL license.
|
* This source file is subject to the GNU GPL license.
|
||||||
*
|
*
|
||||||
* @author David Grudl aka -dgx- <dave@dgx.cz>
|
* @author David Grudl aka -dgx- <dave@dgx.cz>
|
||||||
* @link http://texy.info/dibi/
|
* @link http://dibi.texy.info/
|
||||||
* @copyright Copyright (c) 2005-2006 David Grudl
|
* @copyright Copyright (c) 2005-2006 David Grudl
|
||||||
* @license GNU GENERAL PUBLIC LICENSE v2
|
* @license GNU GENERAL PUBLIC LICENSE v2
|
||||||
* @package dibi
|
* @package dibi
|
||||||
* @category Database
|
* @category Database
|
||||||
* @version 0.6d $Revision$ $Date$
|
* @version 0.6e $Revision$ $Date$
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
define('DIBI', 'Version 0.6d $Revision$');
|
define('DIBI', 'Version 0.6e $Revision$');
|
||||||
|
|
||||||
|
|
||||||
if (version_compare(PHP_VERSION , '5.0.3', '<'))
|
if (version_compare(PHP_VERSION , '5.0.3', '<'))
|
||||||
@@ -84,6 +84,15 @@ class dibi
|
|||||||
FIELD_COUNTER = 'c'; // counter or autoincrement, is integer
|
FIELD_COUNTER = 'c'; // counter or autoincrement, is integer
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Query rrror modes
|
||||||
|
*/
|
||||||
|
const
|
||||||
|
ERR_SILENT = 1,
|
||||||
|
ERR_WARNING = 2,
|
||||||
|
ERR_EXCEPTION = 3;
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Connection registry storage for DibiDriver objects
|
* Connection registry storage for DibiDriver objects
|
||||||
* @var array
|
* @var array
|
||||||
@@ -109,7 +118,11 @@ class dibi
|
|||||||
*/
|
*/
|
||||||
static public $logFile;
|
static public $logFile;
|
||||||
static public $logMode = 'a';
|
static public $logMode = 'a';
|
||||||
static public $errorMode;
|
|
||||||
|
/**
|
||||||
|
* Query error mode
|
||||||
|
*/
|
||||||
|
static public $errorMode = dibi::ERR_SILENT;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Enable/disable debug mode
|
* Enable/disable debug mode
|
||||||
@@ -234,21 +247,27 @@ class dibi
|
|||||||
// and generate SQL
|
// and generate SQL
|
||||||
$trans = new DibiTranslator($conn, self::$substs);
|
$trans = new DibiTranslator($conn, self::$substs);
|
||||||
self::$sql = $trans->translate($args);
|
self::$sql = $trans->translate($args);
|
||||||
if (is_error(self::$sql)) return self::$sql; // reraise the exception
|
|
||||||
|
|
||||||
// execute SQL
|
// execute SQL
|
||||||
$timer = -microtime(true);
|
$timer = -microtime(true);
|
||||||
|
try {
|
||||||
$res = $conn->query(self::$sql);
|
$res = $conn->query(self::$sql);
|
||||||
$timer += microtime(true);
|
self::$error = FALSE;
|
||||||
|
|
||||||
// todo:
|
} catch (DibiException $e) {
|
||||||
self::$error = is_error($res) ? $res : FALSE;
|
$res = FALSE;
|
||||||
|
self::$error = $e;
|
||||||
|
if (dibi::$errorMode === self::ERR_WARNING) {
|
||||||
|
trigger_error('[dibi] ' . $e->getMessage(), E_USER_WARNING);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
$timer += microtime(true);
|
||||||
|
|
||||||
// optional log to file
|
// optional log to file
|
||||||
if (self::$logFile != NULL)
|
if (self::$logFile != NULL)
|
||||||
{
|
{
|
||||||
if (is_error($res))
|
if (self::$error)
|
||||||
$msg = $res->getMessage();
|
$msg = self::$error->getMessage();
|
||||||
elseif ($res instanceof DibiResult)
|
elseif ($res instanceof DibiResult)
|
||||||
$msg = 'object('.get_class($res).') rows: '.$res->rowCount();
|
$msg = 'object('.get_class($res).') rows: '.$res->rowCount();
|
||||||
else
|
else
|
||||||
@@ -261,6 +280,9 @@ class dibi
|
|||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (self::$error && dibi::$errorMode === self::ERR_EXCEPTION)
|
||||||
|
throw self::$error;
|
||||||
|
|
||||||
return $res;
|
return $res;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -280,17 +302,19 @@ class dibi
|
|||||||
if (!is_array($args))
|
if (!is_array($args))
|
||||||
$args = func_get_args();
|
$args = func_get_args();
|
||||||
|
|
||||||
|
$dump = TRUE; // !!! todo
|
||||||
|
|
||||||
// and generate SQL
|
// and generate SQL
|
||||||
|
try {
|
||||||
$trans = new DibiTranslator(self::getConnection(), self::$substs);
|
$trans = new DibiTranslator(self::getConnection(), self::$substs);
|
||||||
$sql = $trans->translate($args);
|
$sql = $trans->translate($args);
|
||||||
$dump = TRUE; // !!!
|
if ($dump) self::dump($sql);
|
||||||
if ($dump) {
|
|
||||||
if (is_error($sql))
|
|
||||||
self::dump($sql->getSql());
|
|
||||||
else
|
|
||||||
self::dump($sql);
|
|
||||||
}
|
|
||||||
return $sql;
|
return $sql;
|
||||||
|
|
||||||
|
} catch (DibiException $e) {
|
||||||
|
if ($dump) self::dump($e->getSql());
|
||||||
|
return FALSE;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@@ -339,9 +363,10 @@ class dibi
|
|||||||
* Prints out a syntax highlighted version of the SQL command
|
* Prints out a syntax highlighted version of the SQL command
|
||||||
*
|
*
|
||||||
* @param string SQL command
|
* @param string SQL command
|
||||||
|
* @param bool return or print?
|
||||||
* @return void
|
* @return void
|
||||||
*/
|
*/
|
||||||
static public function dump($sql) {
|
static public function dump($sql, $return=FALSE) {
|
||||||
static $keywords2 = 'ALL|DISTINCT|AS|ON|INTO|AND|OR|AS';
|
static $keywords2 = 'ALL|DISTINCT|AS|ON|INTO|AND|OR|AS';
|
||||||
static $keywords1 = 'SELECT|UPDATE|INSERT|DELETE|FROM|WHERE|HAVING|GROUP\s+BY|ORDER\s+BY|LIMIT|SET|VALUES|LEFT\s+JOIN|INNER\s+JOIN';
|
static $keywords1 = 'SELECT|UPDATE|INSERT|DELETE|FROM|WHERE|HAVING|GROUP\s+BY|ORDER\s+BY|LIMIT|SET|VALUES|LEFT\s+JOIN|INNER\s+JOIN';
|
||||||
|
|
||||||
@@ -358,8 +383,11 @@ class dibi
|
|||||||
|
|
||||||
// syntax highlight
|
// syntax highlight
|
||||||
$sql = preg_replace_callback("#(/\*.+?\*/)|(\*\*.+?\*\*)|\\b($keywords1)\\b|\\b($keywords2)\\b#", array('dibi', 'dumpHighlight'), $sql);
|
$sql = preg_replace_callback("#(/\*.+?\*/)|(\*\*.+?\*\*)|\\b($keywords1)\\b|\\b($keywords2)\\b#", array('dibi', 'dumpHighlight'), $sql);
|
||||||
|
$sql = '<pre class="dibi">' . $sql . '</pre>';
|
||||||
|
|
||||||
echo '<pre class="dibi">', $sql, '</pre>';
|
// print & return
|
||||||
|
if (!$return) echo $sql;
|
||||||
|
return $sql;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@@ -7,7 +7,7 @@
|
|||||||
* This source file is subject to the GNU GPL license.
|
* This source file is subject to the GNU GPL license.
|
||||||
*
|
*
|
||||||
* @author David Grudl aka -dgx- <dave@dgx.cz>
|
* @author David Grudl aka -dgx- <dave@dgx.cz>
|
||||||
* @link http://texy.info/dibi/
|
* @link http://dibi.texy.info/
|
||||||
* @copyright Copyright (c) 2005-2006 David Grudl
|
* @copyright Copyright (c) 2005-2006 David Grudl
|
||||||
* @license GNU GENERAL PUBLIC LICENSE v2
|
* @license GNU GENERAL PUBLIC LICENSE v2
|
||||||
* @package dibi
|
* @package dibi
|
||||||
@@ -111,7 +111,7 @@ class DibiMySqlDriver extends DibiDriver {
|
|||||||
return new DibiMySqlResult($res);
|
return new DibiMySqlResult($res);
|
||||||
|
|
||||||
if ($res === FALSE)
|
if ($res === FALSE)
|
||||||
return new DibiException("Query error", array(
|
throw new DibiException("Query error", array(
|
||||||
'message' => mysql_error($this->conn),
|
'message' => mysql_error($this->conn),
|
||||||
'code' => mysql_errno($this->conn),
|
'code' => mysql_errno($this->conn),
|
||||||
'sql' => $sql,
|
'sql' => $sql,
|
||||||
|
@@ -7,7 +7,7 @@
|
|||||||
* This source file is subject to the GNU GPL license.
|
* This source file is subject to the GNU GPL license.
|
||||||
*
|
*
|
||||||
* @author David Grudl aka -dgx- <dave@dgx.cz>
|
* @author David Grudl aka -dgx- <dave@dgx.cz>
|
||||||
* @link http://texy.info/dibi/
|
* @link http://dibi.texy.info/
|
||||||
* @copyright Copyright (c) 2005-2006 David Grudl
|
* @copyright Copyright (c) 2005-2006 David Grudl
|
||||||
* @license GNU GENERAL PUBLIC LICENSE v2
|
* @license GNU GENERAL PUBLIC LICENSE v2
|
||||||
* @package dibi
|
* @package dibi
|
||||||
@@ -78,7 +78,7 @@ class DibiMySqliDriver extends DibiDriver {
|
|||||||
return new DibiMySqliResult($res);
|
return new DibiMySqliResult($res);
|
||||||
|
|
||||||
if ($res === FALSE)
|
if ($res === FALSE)
|
||||||
return new DibiException("Query error", $this->errorInfo($sql));
|
throw new DibiException("Query error", $this->errorInfo($sql));
|
||||||
|
|
||||||
$this->affectedRows = mysqli_affected_rows($this->conn);
|
$this->affectedRows = mysqli_affected_rows($this->conn);
|
||||||
if ($this->affectedRows < 0) $this->affectedRows = FALSE;
|
if ($this->affectedRows < 0) $this->affectedRows = FALSE;
|
||||||
|
@@ -7,7 +7,7 @@
|
|||||||
* This source file is subject to the GNU GPL license.
|
* This source file is subject to the GNU GPL license.
|
||||||
*
|
*
|
||||||
* @author David Grudl aka -dgx- <dave@dgx.cz>
|
* @author David Grudl aka -dgx- <dave@dgx.cz>
|
||||||
* @link http://texy.info/dibi/
|
* @link http://dibi.texy.info/
|
||||||
* @copyright Copyright (c) 2005-2006 David Grudl
|
* @copyright Copyright (c) 2005-2006 David Grudl
|
||||||
* @license GNU GENERAL PUBLIC LICENSE v2
|
* @license GNU GENERAL PUBLIC LICENSE v2
|
||||||
* @package dibi
|
* @package dibi
|
||||||
@@ -79,7 +79,7 @@ class DibiOdbcDriver extends DibiDriver {
|
|||||||
return new DibiOdbcResult($res);
|
return new DibiOdbcResult($res);
|
||||||
|
|
||||||
if ($res === FALSE)
|
if ($res === FALSE)
|
||||||
return new DibiException("Query error", $this->errorInfo($sql));
|
throw new DibiException("Query error", $this->errorInfo($sql));
|
||||||
|
|
||||||
$this->affectedRows = odbc_num_rows($this->conn);
|
$this->affectedRows = odbc_num_rows($this->conn);
|
||||||
if ($this->affectedRows < 0) $this->affectedRows = FALSE;
|
if ($this->affectedRows < 0) $this->affectedRows = FALSE;
|
||||||
|
@@ -7,12 +7,12 @@
|
|||||||
* This source file is subject to the GNU GPL license.
|
* This source file is subject to the GNU GPL license.
|
||||||
*
|
*
|
||||||
* @author David Grudl aka -dgx- <dave@dgx.cz>
|
* @author David Grudl aka -dgx- <dave@dgx.cz>
|
||||||
* @link http://texy.info/dibi/
|
* @link http://dibi.texy.info/
|
||||||
* @copyright Copyright (c) 2005-2006 David Grudl
|
* @copyright Copyright (c) 2005-2006 David Grudl
|
||||||
* @license GNU GENERAL PUBLIC LICENSE v2
|
* @license GNU GENERAL PUBLIC LICENSE v2
|
||||||
* @package dibi
|
* @package dibi
|
||||||
* @category Database
|
* @category Database
|
||||||
* @version $Revision: 17 $ $Date: 2006-08-25 20:10:30 +0200 (pá, 25 VIII 2006) $
|
* @version $Revision$ $Date$
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
@@ -84,7 +84,7 @@ class DibiPostgreDriver extends DibiDriver {
|
|||||||
return new DibiPostgreResult($res);
|
return new DibiPostgreResult($res);
|
||||||
|
|
||||||
if ($res === FALSE)
|
if ($res === FALSE)
|
||||||
return new DibiException("Query error", array(
|
throw new DibiException("Query error", array(
|
||||||
'message' => pg_last_error($this->conn),
|
'message' => pg_last_error($this->conn),
|
||||||
'sql' => $sql,
|
'sql' => $sql,
|
||||||
));
|
));
|
||||||
|
@@ -7,7 +7,7 @@
|
|||||||
* This source file is subject to the GNU GPL license.
|
* This source file is subject to the GNU GPL license.
|
||||||
*
|
*
|
||||||
* @author David Grudl aka -dgx- <dave@dgx.cz>
|
* @author David Grudl aka -dgx- <dave@dgx.cz>
|
||||||
* @link http://texy.info/dibi/
|
* @link http://dibi.texy.info/
|
||||||
* @copyright Copyright (c) 2005-2006 David Grudl
|
* @copyright Copyright (c) 2005-2006 David Grudl
|
||||||
* @license GNU GENERAL PUBLIC LICENSE v2
|
* @license GNU GENERAL PUBLIC LICENSE v2
|
||||||
* @package dibi
|
* @package dibi
|
||||||
@@ -78,7 +78,7 @@ class DibiSqliteDriver extends DibiDriver {
|
|||||||
$res = @sqlite_query($this->conn, $sql, SQLITE_ASSOC, $errorMsg);
|
$res = @sqlite_query($this->conn, $sql, SQLITE_ASSOC, $errorMsg);
|
||||||
|
|
||||||
if ($res === FALSE)
|
if ($res === FALSE)
|
||||||
return new DibiException("Query error", array(
|
throw new DibiException("Query error", array(
|
||||||
'message' => $errorMsg,
|
'message' => $errorMsg,
|
||||||
'sql' => $sql,
|
'sql' => $sql,
|
||||||
));
|
));
|
||||||
|
@@ -7,7 +7,7 @@
|
|||||||
* This source file is subject to the GNU GPL license.
|
* This source file is subject to the GNU GPL license.
|
||||||
*
|
*
|
||||||
* @author David Grudl aka -dgx- <dave@dgx.cz>
|
* @author David Grudl aka -dgx- <dave@dgx.cz>
|
||||||
* @link http://texy.info/dibi/
|
* @link http://dibi.texy.info/
|
||||||
* @copyright Copyright (c) 2005-2006 David Grudl
|
* @copyright Copyright (c) 2005-2006 David Grudl
|
||||||
* @license GNU GENERAL PUBLIC LICENSE v2
|
* @license GNU GENERAL PUBLIC LICENSE v2
|
||||||
* @package dibi
|
* @package dibi
|
||||||
@@ -51,9 +51,10 @@ abstract class DibiDriver
|
|||||||
* DibiDriver factory: creates object and connects to a database
|
* DibiDriver factory: creates object and connects to a database
|
||||||
*
|
*
|
||||||
* @param array connect configuration
|
* @param array connect configuration
|
||||||
* @return bool|object DibiDriver object on success, FALSE or Exception on failure
|
* @return DibiDriver
|
||||||
|
* @throw DibiException
|
||||||
*/
|
*/
|
||||||
/*abstract PHP 5.2*/ static public function connect($config) {}
|
/*abstract disallowed PHP 5.2*/ static public function connect($config) {}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@@ -7,7 +7,7 @@
|
|||||||
* This source file is subject to the GNU GPL license.
|
* This source file is subject to the GNU GPL license.
|
||||||
*
|
*
|
||||||
* @author David Grudl aka -dgx- <dave@dgx.cz>
|
* @author David Grudl aka -dgx- <dave@dgx.cz>
|
||||||
* @link http://texy.info/dibi/
|
* @link http://dibi.texy.info/
|
||||||
* @copyright Copyright (c) 2005-2006 David Grudl
|
* @copyright Copyright (c) 2005-2006 David Grudl
|
||||||
* @license GNU GENERAL PUBLIC LICENSE v2
|
* @license GNU GENERAL PUBLIC LICENSE v2
|
||||||
* @package dibi
|
* @package dibi
|
||||||
@@ -55,16 +55,12 @@ class DibiException extends Exception
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
} // class DibiException
|
public function __toString()
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Checks result state
|
|
||||||
*/
|
|
||||||
function is_error($var)
|
|
||||||
{
|
{
|
||||||
return ($var === FALSE) || ($var instanceof Exception);
|
$s = parent::__toString();
|
||||||
|
if (isset($this->info['sql']))
|
||||||
|
$s .= "\nSQL: " . $this->info['sql'];
|
||||||
|
return $s;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
} // class DibiException
|
||||||
|
@@ -7,7 +7,7 @@
|
|||||||
* This source file is subject to the GNU GPL license.
|
* This source file is subject to the GNU GPL license.
|
||||||
*
|
*
|
||||||
* @author David Grudl aka -dgx- <dave@dgx.cz>
|
* @author David Grudl aka -dgx- <dave@dgx.cz>
|
||||||
* @link http://texy.info/dibi/
|
* @link http://dibi.texy.info/
|
||||||
* @copyright Copyright (c) 2005-2006 David Grudl
|
* @copyright Copyright (c) 2005-2006 David Grudl
|
||||||
* @license GNU GENERAL PUBLIC LICENSE v2
|
* @license GNU GENERAL PUBLIC LICENSE v2
|
||||||
* @package dibi
|
* @package dibi
|
||||||
|
@@ -7,7 +7,7 @@
|
|||||||
* This source file is subject to the GNU GPL license.
|
* This source file is subject to the GNU GPL license.
|
||||||
*
|
*
|
||||||
* @author David Grudl aka -dgx- <dave@dgx.cz>
|
* @author David Grudl aka -dgx- <dave@dgx.cz>
|
||||||
* @link http://texy.info/dibi/
|
* @link http://dibi.texy.info/
|
||||||
* @copyright Copyright (c) 2005-2006 David Grudl
|
* @copyright Copyright (c) 2005-2006 David Grudl
|
||||||
* @license GNU GENERAL PUBLIC LICENSE v2
|
* @license GNU GENERAL PUBLIC LICENSE v2
|
||||||
* @package dibi
|
* @package dibi
|
||||||
@@ -50,6 +50,7 @@ class DibiTranslator
|
|||||||
*
|
*
|
||||||
* @param array
|
* @param array
|
||||||
* @return string
|
* @return string
|
||||||
|
* @throw DibiException
|
||||||
*/
|
*/
|
||||||
public function translate($args)
|
public function translate($args)
|
||||||
{
|
{
|
||||||
@@ -109,7 +110,7 @@ class DibiTranslator
|
|||||||
$sql = preg_replace('#\/\*.*?\*\/#s', '', $sql);
|
$sql = preg_replace('#\/\*.*?\*\/#s', '', $sql);
|
||||||
|
|
||||||
if ($this->hasError)
|
if ($this->hasError)
|
||||||
return new DibiException('Errors during generating SQL', array('sql' => $sql));
|
throw new DibiException('Errors during generating SQL', array('sql' => $sql));
|
||||||
|
|
||||||
return $sql;
|
return $sql;
|
||||||
}
|
}
|
||||||
|
@@ -2,6 +2,9 @@
|
|||||||
|
|
||||||
require_once '../dibi/dibi.php';
|
require_once '../dibi/dibi.php';
|
||||||
|
|
||||||
|
// required since PHP 5.1.0
|
||||||
|
if (function_exists('date_default_timezone_set'))
|
||||||
|
date_default_timezone_set('Europe/Prague'); // or 'GMT'
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -54,7 +57,7 @@ class TDateTime implements IDibiVariable
|
|||||||
|
|
||||||
// connects to mysqli
|
// connects to mysqli
|
||||||
dibi::connect(array(
|
dibi::connect(array(
|
||||||
'driver' => 'mysqli',
|
'driver' => 'mysql',
|
||||||
'host' => 'localhost',
|
'host' => 'localhost',
|
||||||
'username' => 'root',
|
'username' => 'root',
|
||||||
'password' => 'xxx', // change to real password!
|
'password' => 'xxx', // change to real password!
|
||||||
|
@@ -17,6 +17,8 @@ dibi::connect(array(
|
|||||||
|
|
||||||
|
|
||||||
$res = dibi::query('SELECT * FROM table');
|
$res = dibi::query('SELECT * FROM table');
|
||||||
|
if (is_error($res))
|
||||||
|
die('SQL error');
|
||||||
|
|
||||||
|
|
||||||
// fetch a single value
|
// fetch a single value
|
||||||
|
@@ -28,5 +28,6 @@ $res = dibi::query('SELECT * FROM [nucleus_item] WHERE [inumber] < %i', 38);
|
|||||||
|
|
||||||
$res = dibi::query('SELECT * FROM [*nucleus_item] WHERE [inumber] < %i', 38);
|
$res = dibi::query('SELECT * FROM [*nucleus_item] WHERE [inumber] < %i', 38);
|
||||||
|
|
||||||
|
echo 'See file ', dibi::$logFile;
|
||||||
|
|
||||||
?>
|
?>
|
@@ -7,6 +7,11 @@ pre.dibi { padding-bottom: 10px; }
|
|||||||
require_once '../dibi/dibi.php';
|
require_once '../dibi/dibi.php';
|
||||||
|
|
||||||
|
|
||||||
|
// required since PHP 5.1.0
|
||||||
|
if (function_exists('date_default_timezone_set'))
|
||||||
|
date_default_timezone_set('Europe/Prague'); // or 'GMT'
|
||||||
|
|
||||||
|
|
||||||
// mysql
|
// mysql
|
||||||
dibi::connect(array(
|
dibi::connect(array(
|
||||||
'driver' => 'mysql',
|
'driver' => 'mysql',
|
||||||
|
@@ -1 +1 @@
|
|||||||
Dibi Version 0.6d
|
Dibi Version 0.6e
|
||||||
|
Reference in New Issue
Block a user