csv导入报错修复
This commit is contained in:
@@ -207,6 +207,7 @@ class Source extends QfShop
|
|||||||
$extension = pathinfo($file_name, PATHINFO_EXTENSION);
|
$extension = pathinfo($file_name, PATHINFO_EXTENSION);
|
||||||
if ($extension == 'csv') {
|
if ($extension == 'csv') {
|
||||||
$PHPReader = new \PHPExcel_Reader_CSV();
|
$PHPReader = new \PHPExcel_Reader_CSV();
|
||||||
|
$encoding = $this->detectFileEncoding($file_name);
|
||||||
$PHPReader->setInputEncoding($encoding);
|
$PHPReader->setInputEncoding($encoding);
|
||||||
$PHPReader->setDelimiter(',');
|
$PHPReader->setDelimiter(',');
|
||||||
} elseif ($extension == 'xlsx') {
|
} elseif ($extension == 'xlsx') {
|
||||||
|
|||||||
Reference in New Issue
Block a user