From: Norman M. <no...@se...> - 2007-07-25 08:06:31
|
Hi folks, the new branch 0.6.0 is now in a state that some else could take it over. It is far from being perfect, but this little code fragment will produce an spreadsheet document, that could be read at least by OpenOffice Calc: <?php require_once 'OpenDocumentPHP/util/Spreadsheet/Writer.php'; // Creating a workbook $workbook = new Spreadsheet_OpenDocument_Writer('test.ods'); // Creating a worksheet $worksheet = $workbook->addWorksheet('My first worksheet'); // The actual data $worksheet->write(0, 0, 'Name'); $worksheet->write(0, 1, 'Age'); $worksheet->write(1, 0, 'John Smith'); $worksheet->write(1, 1, 30); $worksheet->write(2, 0, 'Johann Schmidt'); $worksheet->write(2, 1, 31); $worksheet->write(3, 0, 'Juan Herrera'); $worksheet->write(3, 1, 32); // Let's write the file $workbook->close(); ?> A lot of work is still to be done and I will help any volunteer who wants to take the branch 0.6.0 and make the part in OpenDocumentPHP/util/Spreadsheet/ ready for production. Please contact me ASAP. Yours, Norman |