I create a function to read an excel file using PHPExcel like this below :
function Read_Excel($fname=null,$isheet=0,$irow=1,$icol='A'){
$inputFileName = $fname;
try {
$inputFileType = PHPExcel_IOFactory::identify($inputFileName);
$objReader = PHPExcel_IOFactory::createReader($inputFileType);
$objPHPExcel = $objReader->load($inputFileName);
} catch(Exception $e) {
die('Error loading file "'.pathinfo($inputFileName,PATHINFO_BASENAME).'": '.$e->getMessage());
}
$sheet = $objPHPExcel->getSheet(intval($isheet));
$highestRow = $sheet->getHighestRow();
$highestColumn = $sheet->getHighestColumn();
for ($row = intval($irow); $row <= $highestRow; $row++){
// Read a row of data into an array
$rowData = $sheet->rangeToArray($icol . $row . ':' . $highestColumn . $row,NULL,TRUE,FALSE);
$rec_tbl[] = $rowData[0];
}
return $rec_tbl;
}
you just need to change the $irow=1
in the function parameters to get a row you wanted.