From 54c9ceb0f4890c7f183842f9c3adefaad64c471b Mon Sep 17 00:00:00 2001 From: patdenice Date: Sun, 21 Mar 2010 21:15:54 +0000 Subject: feature 1255: add pwg_select_db function. git-svn-id: http://piwigo.org/svn/trunk@5230 68402e56-0260-453c-a942-63ccdbb3a9ee --- include/dblayer/functions_sqlite.inc.php | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) (limited to 'include/dblayer/functions_sqlite.inc.php') diff --git a/include/dblayer/functions_sqlite.inc.php b/include/dblayer/functions_sqlite.inc.php index 17ef6d576..ce426b9e0 100644 --- a/include/dblayer/functions_sqlite.inc.php +++ b/include/dblayer/functions_sqlite.inc.php @@ -33,7 +33,7 @@ define('DB_RANDOM_FUNCTION', 'RANDOM'); * */ -function pwg_db_connect($host, $user, $password, $database) +function pwg_db_connect($host, $user, $password, $database, $die=true) { global $conf; @@ -50,7 +50,7 @@ function pwg_db_connect($host, $user, $password, $database) try { $link = new SQLite3($db_file, $sqlite_open_mode); } catch (Exception $e) { - my_error('sqlite::open', true); + my_error('sqlite::open', $die); } $link->createFunction('now', 'pwg_now', 0); @@ -64,6 +64,11 @@ function pwg_db_connect($host, $user, $password, $database) return $link; } +function pwg_select_db($database=null, $link=null, $die=null) +{ + return true; +} + function pwg_db_check_charset() { return true; -- cgit v1.2.3