I have installed xampp 1.7.3 and the php version is PH开发者_如何学运维P 5.3.1.When iam using the function domxml_open_file() ,it throwing an error Call to undefined function domxml_open_file().
How i can enable DOM in php.Thanks in advance.
I canot find 'extension=php_domxml.dll'
in php.ini file,
so i added extension=php_domxml.dll this in php.ini file
DOMXML is the old PHP4 XML extension and no longer bundled with PHP5. You have to get it from PECL:
This » PECL extension is not bundled with PHP. Information for installing this PECL extension may be found in the manual chapter titled Installation of PECL extensions. Additional information such as new releases, downloads, source files, maintainer information, and a CHANGELOG, can be located here: » http://pecl.php.net/package/domxml.
Note that A DLL for this PECL extension is currently unavailable.
PHP5 features a new DOM extension, which (among others) should be available out of the box:
$dom = new DOMDocument;
Have a look at some of my previous answers involving DOM usage and also see this article on DevZone for an overview of the available XML extensions in PHP5.
check phpinfo() if php was compiled with --with-libxml-dir
精彩评论