Quantcast
Channel: PHPExcel Forum Rss Feed
Viewing all articles
Browse latest Browse all 2707

New Post: problem with downloading excel from php://output

$
0
0

I saw your answer in

http://stackoverflow.com/questions/5999939/how-to-download-excel-file-in-internet-explorer-browser-with-phpexcel-library

and i am using ssl, does this have anything to do with my problem? I can't get a prompt for downloading with readfile()  either. What a mess! Oh and Mark sorry for disturbing you.

 

$objWriter->save($path);
$excel->disconnectWorksheets(); 
unset($excel);    
    if (file_exists($path)) {
       header('Content-Description: File Transfer');
           header('Content-Transfer-Encoding: binary');
 header('Content-Disposition: attachment;filename=$legit');
  header('Content-Type: application/vnd.ms-excel;charset=UTF-8;');
 header('Content-Length: ' . filesize($path));
  header('Pragma: no-cache');
  header('Expires: 0');
  ob_clean();
    flush();
  @readfile($path);
  exit;
}

I can upload a screenshot of firebug's console if you like to see that everything is done right.


Viewing all articles
Browse latest Browse all 2707

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>