PHP Processing XML files
One
Read, update (create or manipulate) an XML document that requires an XML parser
。 There are two types of XML parsers:
1. tree-based parser:
Convert an XML document into a DOM tree structure
Dom Parser in PHP
See details
Http://www.w3schools.com/php/php_xml_dom.asp
2. Event-based parser:
Reads an XML document and then considers the contents of the XML as events, and a particular function is called when a specific event occurs
PHP for Expat parser
See details
Http://www.w3schools.com/php/php_xml_parser_expat.asp
and http://www.w3schools.com/php/php_ref_xml.asp
Faster than tree-based parser.
Second, PHP can be used in other classes to access the XML file library also has
SimpleXML Functions
Http://www.w3schools.com/php/php_ref_simplexml.asp
PHP Libxml Functions
Http://www.w3schools.com/php/php_ref_libxml.asp
Select the most appropriate XML parser to read and parse the XML document according to the actual situation.
Turn
http://blog.csdn.net/omohe/article/details/1924643