XXIV. DOM XML Functions
Introduction
Warning
This extension is EXPERIMENTAL. The behaviour of this extension
-- including the names of its functions and anything else
documented about this extension -- may change without notice
in a future release of PHP. Use this extension at your own
risk.
The DOM XML extension has been overhauled in PHP 4.3.0
to better comply with the DOM standard. The extension still
contains many old functions, but they should no longer be
used. In particular, functions that are not object-oriented
should be avoided.
The extension allows you to operate on an XML document
with the DOM API. It also provides a function domxml_xmltree()
to turn the complete XML document into a tree of PHP objects.
Currently, this tree should be considered read-only - you
can modify it, but this would not make any sense since DomDocument_dump_mem()
cannot be applied to it. Therefore, if you want to read
an XML file and write a modified version, use DomDocument_create_element(),
DomDocument_create_text_node(), set_attribute(), etc. and
finally the DomDocument_dump_mem() function.
Requirements
This extension makes use of the GNOME XML library. Download
and install this library. You will need at least libxml-2.4.14.
To use DOM XSLT features you can use the libxslt library
and EXSLT enhancements from http://www.exslt.org/. Download
and install these libraries if you plan to use (enhanced)
XSLT features. You will need at least libxslt-1.0.18.
|