]> git.joonet.de Git - adminer.git/commitdiff
Support PHP 7
authorJakub Vrana <jakub@vrana.cz>
Sun, 24 Jan 2016 20:02:10 +0000 (12:02 -0800)
committerJakub Vrana <jakub@vrana.cz>
Sun, 24 Jan 2016 20:02:41 +0000 (12:02 -0800)
adminer/drivers/mysql.inc.php
adminer/include/version.inc.php
changes.txt

index 51aa407284eebd0b083563196aa3ba801c28d473..98e7bf1b02650be4cfcc044ba750a7f2c0816caa 100644 (file)
@@ -13,16 +13,16 @@ if (!defined("DRIVER")) {
                                parent::init();
                        }
 
-                       function connect($server, $username, $password) {
+                       function connect($server = "", $username = "", $password = "", $database = null, $port = null, $socket = null) {
                                mysqli_report(MYSQLI_REPORT_OFF); // stays between requests, not required since PHP 5.3.4
                                list($host, $port) = explode(":", $server, 2); // part after : is used for port or socket
                                $return = @$this->real_connect(
                                        ($server != "" ? $host : ini_get("mysqli.default_host")),
                                        ($server . $username != "" ? $username : ini_get("mysqli.default_user")),
                                        ($server . $username . $password != "" ? $password : ini_get("mysqli.default_pw")),
-                                       null,
+                                       $database,
                                        (is_numeric($port) ? $port : ini_get("mysqli.default_port")),
-                                       (!is_numeric($port) ? $port : null)
+                                       (!is_numeric($port) ? $port : $socket)
                                );
                                return $return;
                        }
index 54f5cd446fb84e1ec206d613e1b8980fc377bbca..a3a79bb2145b678eb013acc788978f73ee703463 100644 (file)
@@ -1,2 +1,2 @@
 <?php
-$VERSION = "4.2.3";
+$VERSION = "4.2.4-dev";
index d9f7286fb689025b28df3d07d2013224a6365760..e3faec267c55e9fcc41cf332b0d07bd475b24237 100644 (file)
@@ -1,3 +1,6 @@
+Adminer 4.2.4-dev:
+MySQL: Support PHP 7
+
 Adminer 4.2.3 (released 2015-11-15):
 Fix XSS in indexes (non-MySQL only)
 Support PHP 7