RE: [PHP-DB] exporting data to excel
Do you set the content-type in the response header like in JSP and servlets? I've been reading the PHP Manual; where do you find stuff like this? Mark -Original Message- From: John W. Holmes [mailto:[EMAIL PROTECTED] Sent: Wednesday, March 24, 2004 9:02 PM To: matthew perry Cc: [EMAIL PROTECTED] Subject: Re: [PHP-DB] exporting data to excel matthew perry wrote: I am looking for the easiest way to export data to an excel file. Is the easiest way to use PHP's file handling functions? Easiest way is to just send Excel headers and output an HTML table. Excel will convert it to a spreadsheet. -- ---John Holmes... Amazon Wishlist: www.amazon.com/o/registry/3BEXC84AB3A5E/ php|architect: The Magazine for PHP Professionals www.phparch.com -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP-DB] exporting data to excel
Do you set the content-type in the response header like in JSP and servlets? I've been reading the PHP Manual; where do you find stuff like this? take a look at the header function http://php.net/header an example...ymmv 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); If you want to generate excel files with more features, take a look on phpclasses.org. There is a PHP port of the Perl Module SpreadsheetWriteExcell... HTH Jeff ___ -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP-DB] exporting data to excel
way cool - thanks for the clues! Mark It's better to TEACH a man how to fish than to GIVE him a fish! -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Sent: Thursday, March 25, 2004 7:46 AM take a look at the header function http://php.net/header an example...ymmv 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); If you want to generate excel files with more features, take a look on phpclasses.org. There is a PHP port of the Perl Module SpreadsheetWriteExcell... HTH Jeff ___ -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP-DB] exporting data to excel
heh heh - last week I attempted to print the Manual...didn't realize the sucker is 2500 pages long until the printer ran out of paper...and the buffer overflowed. Mark -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Sent: Thursday, March 25, 2004 7:54 AM To: Galbreath, Mark A Cc: '[EMAIL PROTECTED]' Subject: RE: [PHP-DB] exporting data to excel Do you set the content-type in the response header like in JSP and servlets? I've been reading the PHP Manual; where do you find stuff like this? take a look at the header function http://php.net/header an example...ymmv 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); If you want to generate excel files with more features, take a look on phpclasses.org. There is a PHP port of the Perl Module SpreadsheetWriteExcell... HTH Jeff ___ -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-DB] exporting data to excel
I am looking for the easiest way to export data to an excel file. Is the easiest way to use PHP's file handling functions? -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP-DB] exporting data to excel
Isn't that better to use excel com object? -Original Message- From: matthew perry [mailto:[EMAIL PROTECTED] Sent: Thursday, March 25, 2004 9:30 AM To: [EMAIL PROTECTED] Subject: [PHP-DB] exporting data to excel I am looking for the easiest way to export data to an excel file. Is the easiest way to use PHP's file handling functions? -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-DB] exporting data to excel
matthew perry wrote: I am looking for the easiest way to export data to an excel file. Is the easiest way to use PHP's file handling functions? Easiest way is to just send Excel headers and output an HTML table. Excel will convert it to a spreadsheet. -- ---John Holmes... Amazon Wishlist: www.amazon.com/o/registry/3BEXC84AB3A5E/ php|architect: The Magazine for PHP Professionals www.phparch.com -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php