简体   繁体   中英

How to make nuSoap work with CakePHP?

I have already put nusoap folder in cakephp vendor folder

../vendor/nusoap/lib/nusoap.php (it has more than one files)

I'm trying to include it as following but not working. What are the other alternatives?

App::import('vendor','nusoap');

There's an example here as to how to set it up: http://phpdev.ro/soap-webservices-in-cakephp.html

For the client(from the example):

  1. import the nusoap library: App::import('Vendor','nusoap');
  2. $client = new nusoap_client('http://yourdomain.com/webservices');
  3. $result = $client->call('helloWorld', array('params' => array('name' => 'Andrew' ) ) );
  4. print_r($result);

您可以使用此代码包含文件

App::import('Vendor', 'nusoap', array('file' => 'nusoap'.DS.'lib'.DS.'nusoap.php'));

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM