require_once("05featuredemo.inc.php"); require_once('Classes/PHPExcel/Writer/CSV.php'); require_once('Classes/PHPExcel/Reader/CSV.php'); require_once('Classes/PHPExcel/Writer/Excel2007.php'); //Write to CSV format 写 $objWriter = new PHPExcel_Writer_CSV($objPHPExcel); $objWriter->setDelimiter(';'); $objWriter->setEnclosure(''); $objWriter->setLineEnding("\r\n"); $objWriter->setSheetIndex(0); $objWriter->save(str_replace('.php', '.csv', __FILE__)); //Read from CSV format 读 $objReader = new PHPExcel_Reader_CSV(); $objReader->setDelimiter(';'); $objReader->setEnclosure(''); $objReader->setLineEnding("\r\n"); $objReader->setSheetIndex(0); $objPHPExcelFromCSV = $objReader->load(str_replace('.php', '.csv', __FILE__)); //Write to Excel2007 format $objWriter2007 = new PHPExcel_Writer_Excel2007($objPHPExcelFromCSV); $objWriter2007->save(str_replace('.php', '.xlsx', __FILE__));
5.写html