fix(db): mysqli_report(MYSQLI_REPORT_OFF) 兼容 PHP 8.1+ 异常模式
2 个文件变更
+2
-0
13172193298@163.com
| •MPHX/db.class.php | +1 -0 |
| •install/db.class.php | +1 -0 |
变更内容
diff --git a/MPHX/db.class.php b/MPHX/db.class.php
index 525f6bd..d40c960 100644
--- a/MPHX/db.class.php
+++ b/MPHX/db.class.php
@@ -60,6 +60,7 @@ if(defined('SQLITE')==true){
}
}
elseif(extension_loaded('mysqli') && $nomysqli==false) {
+ mysqli_report(MYSQLI_REPORT_OFF);
class DB {
var $link = null;
diff --git a/install/db.class.php b/install/db.class.php
index d70fdb7..7eea61c 100644
--- a/install/db.class.php
+++ b/install/db.class.php
@@ -1,6 +1,7 @@
<?php
if(extension_loaded('mysqli')) {
+ mysqli_report(MYSQLI_REPORT_OFF);
class DB {
private static $link;
public static function connect($db_host,$db_user,$db_pass,$db_name,$db_port){