PHPExcel Reader Example #18

Reading list of WorkSheets without loading entire file

'; $reader = \PhpOffice\PhpSpreadsheet\IOFactory::createReader($inputFileType); $worksheetNames = $reader->listWorksheetNames($inputFileName); echo '

Worksheet Names

'; echo '
    '; foreach ($worksheetNames as $worksheetName) { echo '
  1. ', $worksheetName, '
  2. '; } echo '
'; ?>