I'm getting error 500 when i try to read xlsx file using PHPExcel Api.
When i read file from input:
$objReader->load($_FILES['file']['tmp_name']);
=> it's not working. i get this error:
Message: Could not open for reading! File does not exist.
However when i log $_FILES['file']['tmp_name']
i get the file path:
C:\wamp64\tmp\xxxx.tmp
and when i try another file like this:
$objReader->load('c://test.xlsx);
it works
Controller:
$this->load->library('excel');
$objReader = PHPExcel_IOFactory::createReader('Excel2007');
$objPHPExcel = $objReader->load($_FILES['file']['tmp_name']);
print $objPHPExcel->getActiveSheet()->getCell('B1')->getValue();