when loading an xml document and converting to an array using
json_decode(json_encode(simplexml_load_string($xml)), 1);
All empty xml nodes (<node />) are converted to array() I would like them to be an empty string instead. Do I need to go through all elements and replace each empty node with something else?
I am loading the xml document with $xml = new SimpleXmlElement($this->feed_uri, LIBXML_NOBLANKS | LIBXML_NOEMPTYTAG , true);