Craig McCoy

Programmer / Developer & Zombie Survivalist

SimpleXMLElement Object CDATA Empty

Sep/2010 09

If you have CDATA tags in your XML and you use the SimpleXMLElement Object, you will run into problems if you don't add the LIBXML_NOCDATA parameter.
http://php.net/manual/en/libxml.constants.php

$rval = new SimpleXMLElement($xml_data, LIBXML_NOCDATA);