Menu
Hi,
I have a webpage which displays data in report views format. So basically a table. I am looking for a php script of somesort that will download the data into excel.
I have the below which opens up excel but the data does not download.
<?php
$filename = “excel download.xls”;
header(“Pragma: public”); $display=”attachment”;
header(‘Content-Type: application/vnd.ms-excel’);
header(“Content-Disposition: $display; filename=$filename”);
header(“Cache-Control: no-cache”);
?>
Thanks,
Baz