Fatal error: Class 'SoapClient' not found after upgrading PHP from version 7.0 to 7.2
To install SOAP in PHP 7.2 run following in your Ubuntu 16.04 terminal:
- sudo apt-get install php7.2-soap
- sudo service apache2 restart
Look up the following inside your script file
phpinfo();
Do the following:
1.Locate php.ini
in your apache bin folder, I.e Apache/bin/php.ini
.Remove the ;
from the beginning of extension=php_soap.dll
2.Restart your Apache server
EDIT:
For your problem you only need to install soap.
Run sudo apt-get install php7.2-soap
to install soap and also run sudo service php7.2-fpm restart
and sudo service apache2 restart
and your problem fixed!
First, check by phpinfo();
This will show you Soap Client
is it enable or not
If it is disabled Do the following:
- Locate php.ini in your apache bin folder, I.e Apache/bin/php.ini
- Remove the ; from the beginning of extension=php_soap.dll
- Restart your Apache server
- Look up your phpinfo(); again and check
If extension=php_soap.dll
not found in your php.ini
follow below steps
- sudo apt-get install php7.2-soap
- sudo service apache2 restart