这属于php的技术;
php可以用PHPExcel直接导出成excel文件;
代码如下:
require_once("../lib/excelcreator.class.php");
$myxls = new ExcelCreator ("中文Excel");
$aTableHead = '
<Row ss:AutoFitHeight="0">
<Cell><Data ss:Type="String">Name3</Data></Cell> <Cell><Data ss:Type="String">Surname3</Data></Cell> </Row>';
$aTableBody = '
<Row ss:AutoFitHeight="0">
<Cell><Data ss:Type="String">Schwarz3</Data></Cell> <Cell><Data ss:Type="String">Oliver3</Data></Cell> </Row>';
$aTableBottom = '
<Row ss:AutoFitHeight="0">
<Cell><Data ss:Type="String">123</Data></Cell> <Cell><Data ss:Type="String">Peter3</Data></Cell> </Row>';
$workSheet = $myxls->createWorkSheet ( "中文sheet1", $aTableHead, $aTableBody, $aTableBottom );
echo $myxls->createExcel ( $workSheet );