News Feed
Jobs Feed
Sections




News Archive
Ben Ramsey's Blog:
Add Children with SimpleXML
May 11, 2006 @ 20:03:57

In this new post on Ben Ramsey's blog today, he shares his experiences with SimpleXML, mentioning specifically some of the undocumented functions that he's noticed.

I was very excited today while glancing through the code in ext/simplexml/simplexml.c to find some, as of yet, undocumented methods in PHP's SimpleXMLElement class. This discovery came after I've spent several hours over the last couple of nights banging my head against the desk to figure out a way to create a class that extends SimpleXMLElement and adds a new method for adding a child, which would have to use DOM in order to work-or so I thought.

Of course, it's wasn't as easy as it seemed, and Ben soon found some of the limitations of the SimpleXML library. Of course, he did manage to find a way to add new children to the document you're working with (something that normally would have required the intervention of the DOM functionality). Check out the post for a code example.

1 comment voice your opinion now!
simplexml add children undocumented feature methods dom xml simplexml add children undocumented feature methods dom xml


blog comments powered by Disqus

Similar Posts

Matthew Turland's Blog: New SPL Features in PHP 5.3 Webcast Slides

Zend Developer Zone: Webinar - New in Zend Framework 1.10!

Sameer Borate's Blog: PHP 5.4.0 in a nutshell

Developer Tutorials Blog: 5 PEAR gems: free php scripts that will help you code quicker

DevShed: Searching and Replacing Nodes with SimpleXML in PHP 5 (Part 3)


Community Events









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


language event testing example interview community composer opinion introduction code development podcast tool release functional api unittest object framework zendframework2

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