Hi all. I've been tiring to play with SOAP all day with little luck.
The example code
$c = new SoapClient('http://mysite.com/soap/v1/wsdl');
echo $c->getXML("MyClassName", 99); // gets record #99 as xml
Was producing fatal errors.
I've tried creating a SoapClient in non WSDL mode. I don't really understand it all. But this appears to work. But I think the URI is wrong, and I don't know what the URI would be.
$c = new SoapClient(null,
"location" => "http://localhost/ss/silverstripe-v2.3.4/soap/v1/wsdl",
"uri" => "",
'encoding' => SOAP_ENCODED,
'soap_version' => SOAP_1_1,
"style" => SOAP_RPC,
"use" => SOAP_ENCODED,
When I visit the wsdl I see
Wouldn't I want to use SOAPModelAccess/wsdl instead of soap/v1/wsdl when setting up the soap client. It produces the same errors. But I remember reading something about using the same namespace as on the wsdl.
I'm using windows on my localhost, and PHP 5.2.6. There was a bug with windows PHP and SOAP but I think it's OK now. I've tried making a connection with a SilverStripe install on my Linux host, but exact same issue.