tags:

views:

613

answers:

1

With the SoapClient class on PHP5.x and working against a SOAP web service that has optional parameters in its methods, you won't have any problem if you use the non-wsdl mode.

But, at least by default, with the wsdl mode, if you don't fill all the parameters you will get an error like: SOAP-ERROR: Encoding: object hasn't 'xxx' property

Is there any way to avoid that error without working with the non-wsdl mode and without filling all the parameters?

A: 

Maybe this is not the problem with the WSDL mode but with string encoding in the code. If your web service encode strings in UTF-8 make sure you use appropriate functions, like mb_substr(...) instead of substr(...).

czuk