News Feed
Sections




News Archive
Looking for more information on how to do PHP the right way? Check out PHP: The Right Way

Phil Sturgeon's Blog:
PHP Format abstraction with a simple class
February 14, 2011 @ 12:15:13

Phil Sturgeon has posted about a utility he's released that can help convert data from one state to another such as arrays to JSON and XML to CSV - php-format.

Convert between Array, Object, JSON, XML, CSV and Serialized data and back again easily. I'll add a few more types like YAML when I can be arsed to work out PECL for MAMP.

There's a code snippet in his post showing the conversion of an array to JSON then to XML then back to an array. The code is pretty simple to follow with "to" and "from" methods for each format making it simple to extend for your own uses.

0 comments voice your opinion now!
convert data json xml csv serialize


blog comments powered by Disqus

Similar Posts

Project: Aleksey Martynov's lexa-xml-serialization Tool for PHP 5.3

Site News: Blast from the Past - One Year Ago in PHP

Roshan Bhattarai's Blog: How to filter user submitted data easily in PHP?

Community News: Packagist Latest Releases for 03.18.2013

Community News: Packagist Latest Releases for 09.27.2013


Community Events





Don't see your event here?
Let us know!


unittest laravel interview threedevsandamaybe release library developer introduction series code wordpress configure install bugfix api podcast list language application community

All content copyright, 2014 PHPDeveloper.org :: info@phpdeveloper.org - Powered by the Solar PHP Framework