update files inside importify folder
This commit is contained in:
@@ -2,12 +2,13 @@
|
||||
require '../../vendor/autoload.php';
|
||||
|
||||
use PhpOffice\PhpSpreadsheet\IOFactory;
|
||||
if(isset($_FILES['f_csv'])) {
|
||||
|
||||
if (isset($_FILES['f_csv'])) {
|
||||
$file = $_FILES['f_csv']['tmp_name'];
|
||||
$spreadsheet = IOFactory::load($file);
|
||||
$worksheet = $spreadsheet->getActiveSheet();
|
||||
$arr_info = $worksheet->toArray();
|
||||
if(count($arr_info) > 0) {
|
||||
if (count($arr_info) > 0) {
|
||||
die(json_encode($arr_info[0]));
|
||||
} else {
|
||||
die(json_encode(array()));
|
||||
|
||||
Reference in New Issue
Block a user