安装

此扩展默认为启用,编译时可通过下列选项禁用: --disable-simplexml

Note: Before PHP 5.1.2, --enable-simplexml is required to enable this extension.

User Contributed Notes

shashank at shankee dot com 01-Jun-2017 06:44
Installing simpleXml using composer:

"composer require ext-simplexml"

The extension is enabled by default in most distros. You can check the list of php modules using:

"php -m"
morel dot josh at hotmail dot com 17-Dec-2016 09:09
For Linux Ubuntu using PHP 7:
sudo apt-get install php7.0-xml
alvaro at digdib dot com 02-Jan-2009 11:40
Gentoo users: emerge does not compile dev-lang/php with simplexml by default. To enable this option, add the flag simplexml to your USE variable and recompile php.