标签:blog os io for 文件 div cti log sp
function outputCsv($data, $filename = ‘file.csv‘) {//输出文件,下载文件 header(‘Content-Type:application/force-download‘); header("content-Disposition:filename={$filename}"); foreach ($data as $fields) { foreach ($fields as $key => $value) { echo $value . ‘,‘; } echo "\r\n"; } }
php输出cvs文件,下载cvs文件
标签:blog os io for 文件 div cti log sp
原文地址:http://www.cnblogs.com/chenzhaojx/p/3939018.html