switch to mysqli if php5.5 is detected (mysql deprecated)
This commit is contained in:
parent
dfcd778001
commit
3d7f4dc250
@ -3,6 +3,9 @@
|
||||
Version 1.7.1 ()
|
||||
------------------------------------------------------------------------
|
||||
|
||||
* Serendipity will switch to mysqli if PHP >= 5.5 is used (mysql
|
||||
is deprecated)
|
||||
|
||||
* Smarty upgrade to 3.1.14 (read changeLog and the README for API changes since Smarty 2)
|
||||
|
||||
* Upgrader will now remove/delete the browsercompatibility plugin
|
||||
|
@ -7,6 +7,11 @@ if (defined('S9Y_FRAMEWORK_DB')) {
|
||||
}
|
||||
@define('S9Y_FRAMEWORK_DB', true);
|
||||
|
||||
// PHP 5.5 compat, no longer use deprecated mysql
|
||||
if ($serendipity['dbType'] == 'mysql' && (version_compare(PHP_VERSION, '5.5.0' >= 0) || !function_exits('mysql_connect')) {
|
||||
$serendipity['dbType'] = 'mysqli';
|
||||
}
|
||||
|
||||
if (@include(S9Y_INCLUDE_PATH . "include/db/{$serendipity['dbType']}.inc.php")) {
|
||||
@define('S9Y_DB_INCLUDED', TRUE);
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user