php生成excel文件(csv)参考代码如下:
<?php
<?php
header("Content-type:application/vnd.ms-excel");
header("Content-Disposition:attachment;filename=test_data.xls");
//输出内容如下:
echo "姓名"."\t";
echo "年龄"."\t";
echo "学历"."\t";
echo "\n";
echo "张三"."\t";
echo "25"."\t";
echo "本科"."\t";
除非注明,均为湛蓝天空原创,转载请注明本文网址:http://skyhome.cn/php/250.html