I have a symfony2 project and it throws this error on this code exactly
$c = new \SoapClient($objWidget->getLink() . '/ws.php?wsdl');
$objwidget
is not empty and here is the error
Uncaught PHP Exception Symfony\Component\Debug\Exception\ClassNotFoundException: "Attempted to load class "SoapClient" from the global namespace. Did you forget a "use" statement?"
I tried use SoapClient
at the top but still issue with SoapClient
.