Page 1 of 1

Excel and PHP

Posted: Wed Nov 03, 2004 11:42 pm
by Mr Tech
Does anyone know of a good script where you can:

Read Data from a MS Excel File
Put the data from the MS Excel File into a MySQL Database

Thanks

Ben

Posted: Wed Nov 03, 2004 11:44 pm
by Mr Tech
Oh yea, preferably free :)

Posted: Thu Nov 04, 2004 1:42 am
by jollyjumper
Haven't tried this myself, but the description I've read looks promising.

http://www.phpclasses.org/browse/package/1919.html

Microsoft Excel is one of the most popular applications for desktop users, especially as a business work tool. Therefore the generation of spreadsheets in the Excel XLS format is a frequently used feature of Web applications to provide information in a way that lets their users do their work using Excel.

There have always been plenty of solutions to generate spreadsheet files in the XLS format. However, this class provide an innovating approach to the problem of generating XLS files.

This class takes advantage of the stream wrapping capabilities introduced in PHP 4.3 to let applications create XLS files just by using common file handling functions, making the generation of this type of files a trivial task.

Posted: Thu Nov 04, 2004 2:27 am
by ibizconsultants
You could use this:
http://phpclasses.comrax.com/browse/package/1808.html

If you wish to design your own PHP XLS reader module, this could be useful
http://chicago.sourceforge.net/devel/docs/excel/

Hope this helps
http://www.ibizconsultants.com

Posted: Thu Nov 04, 2004 2:35 am
by Mr Tech
Hmm getting a Fatal error: Call to undefined function: stream_wrapper_register() in c:\program files\easyphp\www\excel\excel.php on line 180...

The stream_wrapper_register() doesn't exisit anywhere in any of the files...

Posted: Thu Nov 04, 2004 2:36 am
by Mr Tech
ibizconsultants wrote:You could use this:
http://phpclasses.comrax.com/browse/package/1808.html

If you wish to design your own PHP XLS reader module, this could be useful
http://chicago.sourceforge.net/devel/docs/excel/

Hope this helps
http://www.ibizconsultants.com
I'll have a look :) thanks

Posted: Thu Nov 04, 2004 2:48 am
by Mr Tech

Posted: Thu Nov 04, 2004 10:06 am
by Weirdan
and you can save xls in 'XML spreadsheet' format (I believe it was introduced in Office 2000) which is fairly easy both to parse and write.