Hi all.
I have created an Excel file using PEAR's Excel Writer. If I save the file to my web root (linux) and download it, it is fine. If I send the same file to my desktop using the browser, it is all garbled. Examples are here: http://www.dinnys.com/good.xls and http://www.dinnys.com/bad.xls. I am using the standard headers in Excel Writer to send the file:


function send($filename)
{
header("Content-type: application/vnd.ms-excel");
header("Content-Disposition: attachment; filename=$filename");
header("Expires: 0");
header("Cache-Control: must-revalidate, post-check=0,pre-check=0");
header("Pragma: public");


        header("Content-Length: ". filesize($filename));
                readfile($filename);

    }


Any ideas why the mess?

Thanks,

steve


____ � The WDVL Discussion List from WDVL.COM � ____ To Join wdvltalk, Send An Email To: mailto:[EMAIL PROTECTED] or use the web interface http://e-newsletters.internet.com/discussionlists.html/ Send Your Posts To: [email protected] To change subscription settings, add a password or view the web interface: http://intm-dl.sparklist.com/read/?forum=wdvltalk

________________  http://www.wdvl.com  _______________________

You are currently subscribed to wdvltalk as: [email protected]
To unsubscribe send a blank email to [EMAIL PROTECTED]
To unsubscribe via postal mail, please contact us at:
Jupitermedia Corp.
Attn: Discussion List Management
475 Park Avenue South
New York, NY 10016

Please include the email address which you have been contacted with.

Reply via email to