I basicly need to load the whole XML file, add a new line with content and then saving it. But I wondered which one is faster.. XMLWriter or SimpleXML? Oh, and, it's mainly large XML files, more then 10MB.
Thanks!
I basicly need to load the whole XML file, add a new line with content and then saving it. But I wondered which one is faster.. XMLWriter or SimpleXML? Oh, and, it's mainly large XML files, more then 10MB.
Thanks!
As per PHP's manual, XMLWriter "provides a non-cached, forward-only means of generating streams or files containing XML data."
It cannot be used to load a document and modify it, therefore it's not an option and you're pretty much left with SimpleXML.