PHP SimpleXML CData not loading + solution
Dec 12, 2011 · 1 minute readCategory: php
This is post is now quite old and the the information it contains may be out of date or innacurate.
If you find any errors or have any suggestions to update the information please let us know or create a pull request on GitHub
If you need to access this data then create your xml object like this
$xmlFile = “/path/to/xml/file.xml”;
if (file_exists($xmlFile)) {
$xml = simplexml_load_file($xmlFile,‘SimpleXMLElement’, LIBXML_NOCDATA);
echo $xml->cDataNode;
}