mirror of
https://github.com/Piwigo/Piwigo.git
synced 2026-08-07 09:13:02 +02:00
feature:65 Add support for PHP mysqli extension, activated by default, remove returns of link_identifier
git-svn-id: http://piwigo.org/svn/trunk@20462 68402e56-0260-453c-a942-63ccdbb3a9ee
This commit is contained in:
@@ -40,11 +40,7 @@ function pwg_db_connect($host, $user, $password, $database)
|
||||
{
|
||||
throw new Exception("Can't connect to server");
|
||||
}
|
||||
if (mysql_select_db($database, $link))
|
||||
{
|
||||
return $link;
|
||||
}
|
||||
else
|
||||
if (!mysql_select_db($database, $link))
|
||||
{
|
||||
throw new Exception('Connection to server succeed, but it was impossible to connect to database');
|
||||
}
|
||||
@@ -138,7 +134,7 @@ SELECT IF(MAX('.$column.')+1 IS NULL, 1, MAX('.$column.')+1)
|
||||
return $next;
|
||||
}
|
||||
|
||||
function pwg_db_changes($result)
|
||||
function pwg_db_changes()
|
||||
{
|
||||
return mysql_affected_rows();
|
||||
}
|
||||
@@ -173,14 +169,14 @@ function pwg_db_real_escape_string($s)
|
||||
return mysql_real_escape_string($s);
|
||||
}
|
||||
|
||||
function pwg_db_insert_id($table=null, $column='id')
|
||||
function pwg_db_insert_id()
|
||||
{
|
||||
return mysql_insert_id();
|
||||
}
|
||||
|
||||
function pwg_db_close($link=null)
|
||||
function pwg_db_close()
|
||||
{
|
||||
return mysql_close($link);
|
||||
return mysql_close();
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user