|
||||||
| PHP Forum Use this forum to discuss all aspects of PHP Development. PHP is a server-side, cross-platform, HTML embedded scripting language that lets you create dynamic web pages. |
![]() |
|
|
LinkBack | Thread Tools | Search this Thread | Display Modes |
|
|||
|
Using PHP to parse data how can I then convert that data into an Excel Spreadsheet file?
EX: I retrieve A B C and then next row I get 1 2 3 How can I place that in a spreadsheet looking like this: A B C 1 2 3 |
| Sponsored Links |
|
|
|
|||||
|
I dont believe there is an easy way to do it, I found this code over at phpclasses.org that seems to do what you want
excelwriter.inc.php PHP Code:
PHP Code:
PHP Classes - Class: Excel Writer |
|
|||||
|
Nice code. Alternatively, you can just write a text file that is comma (,) delimited. Use .xls as the extension and it loads fine in excel. Use line breaks for new rows.
__________________
CodeCall Blog | CodeCall Wiki | Shareware Site | Linux Forum | Write a Blog The CodeCall Wiki is now fully integrated with vBulletin users! Check it out and add some new pages! |
|
|||
|
CSV as Jordan has mentioned is far easier than any method lol, but only for small files and can be used for BIGGER ones too but hard to understand if you open with Notepad,
|
| Sponsored Links |
|
|
|
|||||
|
Very hard, and to format properly you need to use commas which can get confusing.
__________________
CodeCall Blog | CodeCall Wiki | Shareware Site | Linux Forum | Write a Blog The CodeCall Wiki is now fully integrated with vBulletin users! Check it out and add some new pages! |
|
|||
|
How interesting that this conversation is taking place. I have been searching without success for information regarding this exact topic.
The fact remains that there are a number of classes written to handle data to and from the xls format. Jordan : Will not the csv format limit itself to single page spreadsheets? However, what I have been looking for is a component \ module or a php app that allows a user to input data within a GUI (primarily in the JOOMLA! framework) and produces complex spreadsheets. Alternatively, takes xls spreadsheets, writes to a db (mySQL) and presents the data to the user within the JOOMLA! framework. Any ideas or comments? Regards, Prakalp. |
|
|||
|
Irrelevant to this particular conversation, however, interesting anyways, is this particular site.
ajaxXLS online based spreadsheet viewer is Live. - Keith Dsouza's Home |
![]() |
| Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | Sea |