WAMP Stack PHP“致命错误:找不到类‘SoapClient’”
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/6760716/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
WAMP Stack PHP "Fatal error: Class 'SoapClient' not found"
提问by chris
I have a WAMP (windows (7), apache, mysql, php) stack all setup and running. All is well and it is working and running as expected. I use the machine primarily for development however it is accessible to the outside world. Anyways..
我有一个 WAMP(windows (7)、apache、mysql、php)堆栈,所有设置和运行。一切都很好,它按预期工作和运行。我使用这台机器主要是为了开发,但它可以被外界访问。无论如何..
I recently come cross a client with a pre-existing SaaS product where cURL, SOAP, and the like are used. I drop there system onto my server and a bit of jumping around to set it up, get it setup, start plugging away at things to only come across a section where I am getting
我最近遇到一个客户,该客户使用了一个预先存在的 SaaS 产品,其中使用了 cURL、SOAP 等。我把那里的系统放到我的服务器上,然后跳来跳去设置它,设置它,开始处理事情,只遇到我得到的部分
Fatal error: Class 'SoapClient' not found
致命错误:找不到“SoapClient”类
Naturally my first jump was i forgot to uncomment
当然,我的第一跳是我忘记取消注释了
extension=php_soap.dll
扩展名=php_soap.dll
Which was true, so I did un-comment it, save the file, then restart the server. However the problem still exists (so I tried even rebooting), now I am stuck as I am not a guru with WAMP/LAMP stacks and configuring them I can only just get around them as needed til now.
这是真的,所以我取消了注释,保存文件,然后重新启动服务器。但是问题仍然存在(所以我什至尝试重新启动),现在我被卡住了,因为我不是 WAMP/LAMP 堆栈的大师,并且配置它们我只能根据需要绕过它们直到现在。
回答by Hossein Shahdoost
This might be a little late now, But I had the similar problem with wamp, and it was because php.ini was different in apache and in cli mode, there was one in apache folder which had php_soap.dll included but the one in php folder which cli was using didn't have it. I add it to the other one and the problem was solved
现在可能有点晚了,但是我在 wamp 上遇到了类似的问题,这是因为 php.ini 在 apache 和 cli 模式下不同,apache 文件夹中有一个包含 php_soap.dll,但在 php 中有一个cli 使用的文件夹没有它。我将它添加到另一个,问题就解决了
回答by DanielX
Do you have a php_soap.dll
in your php/ext/
folder?
你有php_soap.dll
你的php/ext/
文件夹?
回答by Srini Odela
To find the loaded php.ini
file, load the phpinfo()
page.
Navigate to that path and open php.ini
in notepad and search for php_soap.dll
in it.
要查找加载的php.ini
文件,请加载phpinfo()
页面。导航到该路径并php.ini
在记事本中打开并php_soap.dll
在其中搜索。
Uncomment this line and save the file before restarting the server.
在重新启动服务器之前取消注释此行并保存文件。
回答by Jenko
You've probably checked this, but what version of PHP are you using? SoapClient only available after 5.0.1
您可能已经检查过这个,但是您使用的是什么版本的 PHP?SoapClient 仅在 5.0.1 之后可用
回答by John Baber-Lucero
Uncommenting it in php.ini
didn't work. I had to uncomment it in php.ini-development
and php.ini-production
. They were all in C:/BitNami/wampstack-.../php
取消注释它php.ini
不起作用。我不得不在php.ini-development
和 中取消注释php.ini-production
。他们都在C:/BitNami/wampstack-.../php