From f27b7b61ad978ab5988361be7b26a5ccba07d739 Mon Sep 17 00:00:00 2001 From: gongfuxiang <2499232802@qq.com> Date: Sat, 19 Jan 2019 13:40:30 +0800 Subject: [PATCH] =?UTF-8?q?=E5=AE=89=E8=A3=85=E7=BC=96=E7=A0=81=E9=80=89?= =?UTF-8?q?=E6=8B=A9=E4=BF=AE=E5=A4=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- application/install/controller/Index.php | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/application/install/controller/Index.php b/application/install/controller/Index.php index 78d0914c2..9852dde8d 100644 --- a/application/install/controller/Index.php +++ b/application/install/controller/Index.php @@ -259,8 +259,8 @@ return [ 'dsn' => '', // 数据库连接参数 'params' => [], - // 数据库编码默认采用utf8 - 'charset' => '{$this->charset_type_list[$params['DB_CHARSET']]['charset']}', + // 数据库编码默认采用utf8mb4 + 'charset' => '{$params['DB_CHARSET']}', // 数据库表前缀 'prefix' => '{$params['DB_PREFIX']}', // 数据库调试模式 @@ -466,8 +466,8 @@ php; \PDO::ATTR_CASE => \PDO::CASE_LOWER, \PDO::ATTR_EMULATE_PREPARES => true, ], - // 数据库编码默认采用utf8 - 'charset' => 'utf8mb4', + // 数据库编码默认采用utf8mb4 + 'charset' => $params['DB_CHARSET'], // 数据库表前缀 'prefix' => $params['DB_PREFIX'], ]);