 | News Feed |
 | Jobs Feed |
Sections
|
| feed this: |  |
Pablo Viquez's Blog: Export Excel Spreadsheets using Zend Framework
by Chris Cornutt August 25, 2009 @ 07:57:30
New on his blog today Pablo Viquez has this post looking at code that will let your Zend Framework applications export to Microsoft Excel spreadsheets (via the Spreadsheet Excel Writer PEAR component).
Last week, I had to allow the user to export a given report into an MS Excel file format. The application uses Zend Framework 1.9.1 and so far ZF does not support for "Office" formats, so after searching for a nice implementation, I found a PEAR module called Spreadsheet Excel Writter, which looked pretty good, it had very good documentation and the code was clean and well structured so I wanted I give it a shot.
He lays out the structure of the sample application and, using a context switch on the request, he creates a controller that responds to the "/report" by calling a special model/view combination that uses the PEAR package to push out the custom "report.xls" file.
voice your opinion now!
zendframework pear excel spreadsheet
Maarten Balliauw's Blog: Reuse Excel business logic with PHPExcel
by Chris Cornutt May 06, 2008 @ 07:51:38
Maarten Balliauw has made a new blog post today about a method he's using to help reuse some of the business logic that Excel spreadsheets can have in a PHP script with help from PHPExcel.
In many companies, business logic resides in Excel. This business logic is sometimes created by business analysts and sometimes by business users who want to automate parts of their everyday job using Excel. [...] Did you know you can use PHPExcel to take advantage of the Excel-based business logic without having to worry about duplicate business logic?
He creates a quick example of a script that can take in an Excal file and pull it into a PHPExcel object, ready for manipulation. He fills in values for the already defined fields (like "carColor" or "leatherSeats") and uses the getCalculatedValue method to perform the action on the cell. The output is dropped into a variable that can be echoed out or used later on in the PHP script.
voice your opinion now!
phpexcel excel business logic reuse tutorial example
Zend Developer Zone: Reading and Writing Spreadsheets with PHP
by Chris Cornutt April 03, 2008 @ 08:49:19
On the Zend Developer Zone, Vikram Vaswani has posted a tutorial that shows hos to "break the language barrier" between PHP and Microsoft's Excel to allow for the reading and writing of spreadsheet data directly from one to the other.
When it comes to playing nice with data in different formats, PHP's pedigree is hard to beat. Not only does the language make it a breeze to deal with SQL result sets and XML files, but it comes with extensions to deal with formats as diverse as Ogg/Vorbis audio files, ZIP archives and EXIF headers. So it should come as no surprise that PHP can also read and write Microsoft Excel spreadsheets, albeit with a little help from PEAR.
After grabbing the different parts needed (the PHP-ExcelReader package and the Spreadsheet_Excel_Writer PEAR package, he shows how to create a simple spreadsheet with just numeric information in it. For something a bit more interesting, he goes the other way and shows spreadsheet data as an HTML table.
Other examples included as well are things like: pushing spreadsheet data into a database, working with formulas and styling it to your liking.
voice your opinion now!
spreadsheet excel pear package phpexcelreader writer tutorial
|
Community Events
Don't see your event here? Let us know!
|