Quick one, How would you go about checking if your connection to a soap server is actually connecting?
I have this code:
$m_wsdl = "https://m2mconnect.orange.co.uk/orange-soap/services/MessageServiceByCountry?wsdl";
try {
$client = new SoapClient($m_wsdl);
$this->m_messages = $client->peekMessages('','',10,"");
} catch (Exception $e) {
echo "Exception: \n" . $e->getMessage() . "\n";
}
$this->do_parse_xml();
Obviously my username and password are in the peekmessages field where they should be, and they are both correct i am 100%.
For some reason its not returning any data at all and i dont know how to check to see if the connection is actually working??
Im getting no exceptions being echo'd
Thanks for any help
Use isSoapFault()
http://php.net/manual/en/function.is-soap-fault.php
Also, the peekMessages
method would probably return false
or a SoapFault
.
You can also set Exceptions
to true on the SoapClient
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With