
July 20th, 2007, 09:25 AM
|
|
Registered User
|
|
Join Date: Jul 2007
Posts: 1
Time spent in forums: 19 m 32 sec
Reputation Power: 0
|
|
|
Excel Spreadsheet Writer: File Streaming?
Hello,
I am using the PEAR Excel Spreadsheet Writer to generate a formatted excel file, which is working just fine (despite the somewhat weird merging functions, where either the cells are not properly merged (setAlign) or the height of the cell doesn't adapt to the lines present in the string (setMerge)).
Anyway, my real question is, is there some way to "stream" to file?
Currently it seems that first the file is completely generated first, and if the file is rather large (> 1 MB), it takes quite a while before the download as popup message appears.
Before I had found the Spreadsheet Writer, I was simply using the XLS headers
header("Content-type: application/vnd-ms-excel");
header("Content-Disposition: attachment; filename=export.xls");
to output a simple HTML table as an .XLS file.
The download popup would almost start immediately and then the file would be streamed to the client.
Of course, the downside of an HTML table is that actually opening the file in Excel takes forever, which is why I dropped that approach in favor of the PEAR solution.
Now, if I only could get that streaming to work...
|