我现在用的是
// $filename=str_replace('-','',date('Y-m-j'));
// header ( "Content-typefile_type;charset=utf-8" );
// header ( "Content-type:application nd.ms-excel" );
// header ( "Content-Disposition:filename=$filename.xls" );
这种方法来做,但是导入到Excel表中的内容是整个网页上的内容,而不是我想导入的那个表里面的内容,我现在想要的结果就是只想得到表中的内容,不要页面上别的内容不知道大家有没有什么好的办法~~~~~~~~
// $filename=str_replace('-','',date('Y-m-j'));
// header ( "Content-typefile_type;charset=utf-8" );
// header ( "Content-type:application nd.ms-excel" );
// header ( "Content-Disposition:filename=$filename.xls" );
这种方法来做,但是导入到Excel表中的内容是整个网页上的内容,而不是我想导入的那个表里面的内容,我现在想要的结果就是只想得到表中的内容,不要页面上别的内容不知道大家有没有什么好的办法~~~~~~~~
queryphp 简单 MVC ORM框架
---------------------------------------------
http://topic.csdn.net/u/20100310/11/62a60067-b3da-4dee-9d6a-f1baeb2f3f33.html
<?php
require_once '../Classes/PHPExcel.php';require_once '../Classes/PHPExcel/IOFactory.php';
$objPHPExcel = new PHPExcel();// Create new PHPExcel object
$objPHPExcel->setActiveSheetIndex(0)
->setCellValue('A1', 'Hello')
->setCellValue('B2', 'world!')//add some dataheader('Content-Type: application/vnd.ms-excel');
header('Content-Disposition: attachment;filename="hello.xls"');
header('Cache-Control: max-age=0');// Redirect output to a client’s web browser (Excel5)$objWriter = PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel5');
$objWriter->save('php://output');
exit;
?>phpexcel类,搜一把,到处都是