From 6c64bbd82a7a934296886f068662bc8a818fb5d7 Mon Sep 17 00:00:00 2001 From: Alone <675061370@qq.com> Date: Mon, 2 Sep 2024 11:07:14 +0800 Subject: [PATCH] =?UTF-8?q?csv=E5=AF=BC=E5=85=A5=E6=8A=A5=E9=94=99?= =?UTF-8?q?=E4=BF=AE=E5=A4=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/admin/controller/Source.php | 1 + 1 file changed, 1 insertion(+) diff --git a/app/admin/controller/Source.php b/app/admin/controller/Source.php index 5f399b5..c10842d 100644 --- a/app/admin/controller/Source.php +++ b/app/admin/controller/Source.php @@ -207,6 +207,7 @@ class Source extends QfShop $extension = pathinfo($file_name, PATHINFO_EXTENSION); if ($extension == 'csv') { $PHPReader = new \PHPExcel_Reader_CSV(); + $encoding = $this->detectFileEncoding($file_name); $PHPReader->setInputEncoding($encoding); $PHPReader->setDelimiter(','); } elseif ($extension == 'xlsx') {