send('feuille.xls'); } // Creating a worksheet $worksheet =& $workbook->addWorksheet('Feuille'); if (($fp = fopen(CSV_FILE, 'r')) === FALSE) { die(__LINE__ . "\n"); } $row = 0; while (!feof($fp)) { $cells = fgetcsv($fp); if (empty($cells)) { continue; } $col = 0; foreach ($cells as $cell) { $worksheet->write($row, $col, $cell); $col++; } $row++; } fclose($fp); $workbook->close(); ?>