I am using this site as a guide to my webservice..
http://developer.yahoo.com/answers/V1/questionSearch.html
and I use this code:
$client=new SoapClient("http://answers.yahooapis.com/AnswersService/V1/questionSearch");
$resposeArray=$client->__call("query","economics");
var_dump($resposeArray);
Apparently, I fail to retrieve anything.. and get this error:
Fatal error: Uncaught SoapFault exception: [WSDL] SOAP-ERROR: Parsing WSDL: Couldn’t load from ‘http://answers.yahooapis.com/AnswersService/V1/questionSearch’ : failed to load external entity “http://answers.yahooapis.com/AnswersService/V1/questionSearch” in C:\xampp\htdocs\Unnamed Site 2\untitled1.php:11 Stack trace: #0 C:\xampp\htdocs\Unnamed Site 2\untitled1.php(11): SoapClient->SoapClient(‘http://answers….’) #1 {main} thrown in C:\xampp\htdocs\Unnamed Site 2\untitled1.php on line 11
For the webservice to work with your code, PHP must be able to obtain the external file:
However that file doesn’t work any longer and gives back an error:
So the client can’t proceed. Replace it with a working version and try again. It looks like that the URL needs some key, probably with a cookie/header or something, I’m not familiar with that specific webservice.