Zend 1.12.9 How to "Soap Request"

Hi all,

I’m a newbie of Zend and now studying about soap request & response. I get a ‘test.wsdl’ file on hand and perform “new Zend_Soap_Client(‘test.wsdl’)” on php script. According to the ‘test.wsdl’, I need to pass several parameters. They are listed as below.

  1. API_KEY
  2. RECEIPT_NUMBER
  3. OUT_BOUND_FARE_PAID
  4. NAME_OF_TRAVELER_PAYER
  5. DEPARTURE_DATE
  6. LAST_4_DIGIT_OF_CONTACT_PHONE_NUMBER

I try to write the php script as following.

$client = new Zend_Soap_Client(“test.wsdl”);

$data = array(
“API_KEY” => ‘A123456’,
“RECEIPT_NUMBER” => ‘201800001’,
“OUT_BOUND_FARE_PAID” => 105.00,
“NAME_OF_TRAVELER_PAYER” => “Anonymous”,
“DEPARTURE_DATE” => “2018-12-31”,
“LAST_4_DIGIT_OF_CONTACT_PHONE_NUMBER” = 3775
);
$result = $client->LevyEFrank($data);

The given result is:
Message: Not Found

Stack trace:

#0 D:\Wamp64\includes\Zend\Soap\Client.php(995): SoapClient->__doRequest(’_doRequest(Object(Zend_Soap_Client_Common), ‘__doRequest(’__soapCall(‘LevyEFrank’, Array, NULL, NULL, Array) #4 D:\Wamp64\www\travel\application\controllers\IndexController.php(45): Zend_Soap_Client->__call(‘LevyEFrank’, Array) #5 D:\Wamp64\includes\Zend\Controller\Action.php(516): IndexController->indexAction() #6 D:\Wamp64\includes\Zend\Controller\Dispatcher\Standard.php(308): Zend_Controller_Action->dispatch(‘indexAction’) #7 D:\Wamp64\includes\Zend\Controller\Front.php(954): Zend_Controller_Dispatcher_Standard->dispatch(Object(Zend_Controller_Request_Http), Object(Zend_Controller_Response_Http)) #8 D:\Wamp64\includes\Zend\Application\Bootstrap\Bootstrap.php(101): Zend_Controller_Front->dispatch() #9 D:\Wamp64\includes\Zend\Application.php(366): Zend_Application_Bootstrap_Bootstrap->run() #10 D:\Wamp64\www\travel\public\index.php(26): Zend_Application->run() #11 {main}

Request Parameters:

array ( ‘controller’ => ‘index’, ‘action’ => ‘index’, ‘module’ => ‘default’, )

Could anyone teach me how to perform soap request with parmaeters according to WDSL.

Sample of test.wsdl
test.wsdl

Thanks for all in advanced!

ZF 1.x is discontinued: please plan an upgrade instead.

As for your issue, it may be that you need a soap request decorator (see ext-soap’s docs about that).