From which PHP 5 version does simplexml_load_file support CDATA?
$xml = @simplexml_load_file($url, NULL, LIBXML_NOCDATA);
Thanks!!
I'm not entirely sure this answers your question (some clarity might help?) but I found this at php.net:
https://www.php.net/manual/en/function.simplexml-load-file.php#82067
"A PHP version >= 5.1.0 is required for this to work"
LIBXML_NOCDATA option; it is not required to include the CDATA in the object, becase the CDATA is always there - it's just not visible in var_dump, print_r, etcAs in http://php.net/manual/en/function.simplexml-load-file.php said, I think from PHP version >= 5.1.0
SimpleXML supports CDATA in any version, and there is no need to pass LIBXML_NOCDATA. See https://stackoverflow.com/a/13830559/157957 and https://stackoverflow.com/a/16842431/157957
LIBXML_NOCDATAflag?var_dump,print_r, etc, causing confusion. There is no need to passLIBXML_NOCDATAin order to work with SimpleXML in the normal way; for an explanation of what it actually does, see stackoverflow.com/a/13981917/157957