$spreadsheet = PhpOfficePhpSpreadsheetIOFactory::load($file_path); $workSheet = $NamedRanges->getWorksheet(); $definedName = "xxxx"; //获取指定名称对应的数据 $range_array_data = $workSheet->namedRangeToArray($definedName);//当前返回值返回的是行列二维数组