diff --git a/drivers/adodb-mysqli.inc.php b/drivers/adodb-mysqli.inc.php index 07b294caf..5271db178 100644 --- a/drivers/adodb-mysqli.inc.php +++ b/drivers/adodb-mysqli.inc.php @@ -167,6 +167,14 @@ function _connect($argHostname = null, if(!extension_loaded("mysqli")) { return null; } + // Check for a function that only exists in mysqlnd + if (!function_exists('mysqli_stmt_get_result')) { + // @TODO This will be treated as if the mysqli extension were not available + // This could be misleading, so we output an additional error message. + // We should probably throw a specific exception instead. + $this->outp("MySQL Native Driver (msqlnd) required"); + return null; + } $this->_connectionID = @mysqli_init(); if (is_null($this->_connectionID)) {