Very nice code indeed!
I'm using also similair classes like the ones above but can't find a normal way to analyse the output that the soap returns.
How do you people analyse these results? I found out that __soapCall returns an object if the action is succeed but then again when I try to delete a certain account it doesn't return an object.
PHP Code:
function deleteAccount($id = "") {
try {
// needed parameters
$this->params = array(
new SoapParam($id, "id"),
);
// create Soap header
$soapHeader = new SoapHeader(
'urn:zimbra',
'context',
new SoapVar(
'<ns2:context><authToken>' . $this->sAuthToken . '</authToken></ns2:context>',
XSD_ANYXML
)
);
// do Soap Call
$vResult = $this->client->__soapCall("DeleteAccountRequest", $this->params, null,$soapHeader,$output);
} catch (SoapFault $exception) {
if($this->bDebug == true) {
$this->printDebug();
}
}
return $vResult;
}
Anyone have a suggestion how to handle the data that the soapClass returns?