Not sure what my question is here but I need some pointers.
This is part of a guide for sending Insurance policy information to a webservice to get a quote in return. Where 'schema' and 'xml' need to be replaced.
I am using nusoap (PHP soap extensions aren't on the server and I can't install them) and I would normally send something like:
$client->call('Quote', 'PolicyDetails' => $xml);
But this doesn't work. I get the error:
Error: soap:Server: Server was unable to process request. --> Object reference not set to an instance of an object.
I assume because I'm missing out the 'schema' part. I know what the XML should look like but not what I have to add to 'schema' or how I should do it. Can anyone point me in the right direction?
Without the WSDL, I have to guess the structure. You may need parameters like
$schema = array('any' => $schema);
$details = array('schema' => $schema, 'any' => $xml);
$client->call('Quote', 'PolicyDetails' => $details);
For the particular method you are calling, you will be assembling your own XML for 'schema' and 'xml'. As such, you might want to consider creating the whole SOAP payload as a string and passing that as the "parameters" in call().
Log in to post a comment.
Sign up for the SourceForge newsletter:
You seem to have CSS turned off.
Please don't fill out this field.