I'm using PHPExcel version 1.7.9.
Here is my PHP code :
$temp_name = $_FILES['upload']['tmp_name'];
$fname = $_FILES['upload']['name'];
$transfer = move_uploaded_file($temp_name,TEMP_DIR.$fname);
$file_location = TEMP_DIR.$fname;
$inputFileType = PHPExcel_IOFactory::identify($file_location);
$objReader = PHPExcel_IOFactory::createReader($inputFileType);
$objReader->setReadDataOnly(true);
$objPHPExcel = $objReader->load($file_location);
for each line of code above I echo time taken to produce the output
startup Pageload in 0.0272 seconds
upload file Pageload in 0.0408 seconds
Identify File Pageload in 0.0612 seconds
Create Reader Pageload in 0.0613 seconds
Set Read Data OnlyPageload in 0.0613 seconds
File read Pageload in 17.3884 seconds
my question is, why
$objPHPExcel = $objReader->load($file_location);
take 17.3884 seconds to load?
Other information :
- MS Excel 2007
- Size 384kb
- Maximum Column - AF
- Maximum Row = 184 row