<?xml version="1.0"?>
<rss version="2.0">
  <channel>
    <title>PHPDeveloper.org</title>
    <link>http://www.phpdeveloper.org</link>
    <description>Up-to-the Minute PHP News, views and community</description>
    <language>en-us</language>
    <pubDate>Fri, 24 May 2013 17:03:55 -0500</pubDate>
    <ttl>30</ttl>
    <item>
      <title><![CDATA[Content with Style: Remove nodes in SimpleXMLElement]]></title>
      <guid>http://www.phpdeveloper.org/news/12885</guid>
      <link>http://www.phpdeveloper.org/news/12885</link>
      <description><![CDATA[<p>
The Content with Style blog has <a href="http://www.contentwithstyle.co.uk/content/remove-node-in-simplexml">this quick tip</a> on removing nodes from inside of a <a href="http://php.net/simplexml">SimpleXML</a> object without causing problems with its internal handling.
</p>
<blockquote>
You might think otherwise and hack it with unset(), as it was done in one of the web applications I inherited at work, but today I found out that this works under some conditions, but not with every setup. I'd love to tell you what exactly the differences are that make it break, but I didn't spend the time tracking it down.
</blockquote>
<p>
Instead, he suggests a call to <a href="http://php.net/dom_import_simplexml">dom_import_simplexml</a> to swap the object over to the DOM, performing a removeChild on the node and pushing it back over to SimpleXML if the need's there.
</p>]]></description>
      <pubDate>Thu, 16 Jul 2009 11:15:57 -0500</pubDate>
    </item>
    <item>
      <title><![CDATA[DevShed: Parsing Child Nodes with the DOM XML extension in PHP 5]]></title>
      <guid>http://www.phpdeveloper.org/news/9928</guid>
      <link>http://www.phpdeveloper.org/news/9928</link>
      <description><![CDATA[<p>
<i>Alejandro Gervasio</i> has finished up his series on DevShed looking at working with the DOM extension in PHP5 with <A href="http://www.devshed.com/c/a/PHP/Parsing-Child-Nodes-with-the-DOM-XML-extension-in-PHP-5/">this new article</a>, a look at parsing child nodes.
</p>
<blockquote>
In this last chapter of the series, I'm going to teach you how to handle the child nodes of an XML document by way of two simple methods, called hasChildNode() and removeChild() respectively. So let's not waste any more time in preliminaries and learn how to use them in a helpful way.
</blockquote>
<p>
They <a href="http://www.devshed.com/c/a/PHP/Parsing-Child-Nodes-with-the-DOM-XML-extension-in-PHP-5/1/">review</a> some of the concepts mentioned previously before moving ahead to the use of the <a href="http://www.devshed.com/c/a/PHP/Parsing-Child-Nodes-with-the-DOM-XML-extension-in-PHP-5/2/">hasChildNodes</a> and <a href="http://www.devshed.com/c/a/PHP/Parsing-Child-Nodes-with-the-DOM-XML-extension-in-PHP-5/3/">removeChild</a> methods to check for children and get rid of only certain ones.
</p>]]></description>
      <pubDate>Tue, 08 Apr 2008 09:47:48 -0500</pubDate>
    </item>
  </channel>
</rss>
