Re: FN-FORUM: PHP generate xls
date posted 30th October 2007 16:36
On Tue, Oct 30, 2007 at 05:19:56PM -0000, Ben Johnson F wrote:
>
> > The typical way I've seen this done is to generate CSV rather than XLS,
> > as this is easy to generate from any scripting language and is much
> > less of a resource hog than instantiating Office components, etc.
>
> Note that you'll need to set the correct file-type HTTP header etc from your
> scripting language - if this is of interest to someone, let me know and I'll
> post sample ASP code.
He said that he was using PHP:
header("Content-type: text/xml");
header("Content-Disposition: attachment; filename=MeetingReport.xml");
It *really* is easy with PEAR.
--
Alain Williams
Linux Consultant - Mail systems, Web sites, Networking, Programmer, IT Lecturer.
+44 (0) 787 668 0256 http://www.phcomp.co.uk/
Parliament Hill Computers Ltd. Registration Information: http://www.phcomp.co.uk/contact.php
Chairman of UKUUG: http://www.ukuug.org/
#include