php to generate numbers spreadsheet

there is a pear package (http://pear.php.net/package/SpreadsheetExcelWriter) that uses php to generate excel spreadsheets. could this be done with numbers? anyone have any idea what would have to change to use numbers instead of excel?

PowerBook, G5, iPhone, and tv, Mac OS X (10.5.2)

Posted on May 28, 2008 10:51 AM

Reply
3 replies

May 28, 2008 11:04 AM in response to ahs10

ahs10 wrote:
there is a pear package ( http://pear.php.net/package/SpreadsheetExcelWriter) that uses php to generate excel spreadsheets. could this be done with numbers? anyone have any idea what would have to change to use numbers instead of excel?


The structure of a Numbers document is not documented so you will have to study it by reverse engineering which is not a good idea because the format is subject to changes.

Yvan KOENIG (from FRANCE mercredi 28 mai 2008 20:04:05)

May 28, 2008 11:40 AM in response to KOENIG Yvan

that explains quite a bit, thanks.

this could be worth my while though. i've never used numbers and rarely use excel. is anyone aware of any obvious reasons that using numbers for this purpose might be better?

i have modified a version of the spreadsheet excel writer and making graphs is possible but very tedious and extremely limited, could it be that numbers make it easier to do this?

also excel is tricky with the way it stores dates and some of it's formatting information, and a wild little conversion process as to take place to convert from mysql format to a format excel will display properly. maybe numbers might improve this?

finally, the only way i've discovered to effectively upload information from an excel spreadsheet is to first export it to csv (mostly because of this date and formatting issues) then upload it. obviously it'd make more sense to an end-user not have to export a file to a different format. i was hoping numbers might be able to keep a consistent file format instead.

like you said, the structure is not documented, so i doubt you'd know the answers here for sure. but do have any incline at all that any of these points would be improved by using numbers?

thanks again for your time 🙂

May 28, 2008 12:21 PM in response to ahs10

At this time,
XL format is a proprietary one
Numbers format is a proprietary one too.

In the Numbers format, datas are stored in an xml file but the structure of this one is not documented so it would be difficult to parse it.

Since the delivery of the prog, I already met three ways to describe the embedded popUp menu items, so I'm reluctant to say that using this format for what you want would be a good idea.

My hope is that Apple decide to replace the initial format by a new one applying the open doc format adopted some months ago. Doing that, the format would be conform to an universal structure and it would be safer and easier to grab datas from the file.
But caution, it's a dream, not an information.

Yvan KOENIG (from FRANCE mercredi 28 mai 2008 21:21:48)

This thread has been closed by the system or the community team. You may vote for any posts you find helpful, or search the Community for additional answers.

php to generate numbers spreadsheet

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple Account.