Magento: Read Write XML

I will be using Varien_Simplexml_Element class to read write xml nodes. The path to this class file is lib/Varien/Simplexml/Element.php Here is a sample XML file which I am going to read through Magento code. I will also be adding an XML node to the following XML data. <?xml version="1.0"?> <config> <modules> <MyNamespace_MyModule> <version>0.1.0</version> </MyNamespace_MyModule> </modules> … Read more

PHP : Read Write XML with SimpleXML

In this article, I will be showing you how to create and read xml document with php’s SimpleXML extension. The SimpleXML extension provides a very simple and easily usable toolset to convert XML to an object that can be processed with normal property selectors and array iterators. Below is the code to create XML file. … Read more