标签:生成excel表格
header("Content-type:application/vnd.ms-excel"); $filename=‘LBTX‘.time(); header("Content-Disposition:attachment; filename=$filename.xls"); echo ‘编号‘.chr(9).‘流水号‘.chr(9).‘用户名‘.chr(9).‘手机号‘.chr(9).‘openid‘.chr(9).‘可提余额‘.chr(9).‘提现金额‘.chr(9).‘发起时间‘.chr(9).‘最后操作时间‘.chr(9).‘提现状态‘.chr(13); foreach($list as $k=>$v){ echo $v["withdraw_id"].chr(9); echo $v[‘trade_no‘].chr(9); echo $v[‘user_name‘].chr(9); echo $v[‘user_tel‘].chr(9); echo $v[‘openid‘].chr(9); echo $v[‘before_price‘].chr(9); echo $v[‘price‘].chr(9); echo $v[‘create_time‘].chr(9); echo empty($v[‘done_time‘])?$v[‘create_time‘].chr(9):$v[‘done_time‘].chr(9); echo $type[$v[‘withdraw_status‘]].chr(13); }
本文出自 “老头子” 博客,请务必保留此出处http://laotouzi.blog.51cto.com/12411135/1883281
标签:生成excel表格
原文地址:http://laotouzi.blog.51cto.com/12411135/1883281