我们有 CentOS 的 VPS。我已经使用以下命令安装了 SOAP:
$ yum install php-soap
然后我去php.ini
文件取消注释 SOAP 扩展。它不存在,所以我添加了以下行:
extension=soap.so
然后我通过运行重新启动服务器
$ service httpd restart
但是 SOAP 仍然没有启用。
我得到Fatal error: Class 'SoapClient'
消息。
如果我尝试再次安装它,我会收到以下消息:
Package php-soap-5.3.3-27.el6_5.x86_64 already installed and latest version
我也尝试使用以下命令重新配置 PHP:
$ php-config '--disable-fileinfo' '--disable-pdo' '--enable-bcmath' '--enable-calendar' '--enable-ftp' '--enable-libxml' '--enable-sockets' '--prefix=/usr/local' '--with-apxs2=/usr/local/apache/bin/apxs' '--with-curl=/opt/curlssl/' '--with-imap=/opt/php_with_imap_client/' '--with-imap-ssl=/usr' '--with-kerberos' '--with-libdir=lib64' '--with-libxml-dir=/opt/xml2/' '--with-mysql=/usr' '--with-mysql-sock=/var/lib/mysql/mysql.sock' '--with-openssl=/usr' '--with-openssl-dir=/usr' '--with-pcre-regex=/opt/pcre' '--with-pic' '--with-zlib' '--with-zlib-dir=/usr' '--enable-soap'
有什么帮助吗?