http://www.dvbbs.net/tech/php/2006032927139.asp 这里面有个例子, 我按照这个例子 我把nusoap.php放在服务器上 include下。 把 soapclient.php ,soapserver.php,soapfunc.php 这三个文件 放在我得虚拟目录下(soap.test.com) 。 然后我执行 soapclient.php ,却没有 如例子中所说结果出来。 好像没有连接上web service 我打印的结果如下: if you reverse 'this string will be reversed', you get 'Array' if you add 5 and 14 you get Array 请问 ,是我部署有问题呢? 还是其他原因?请教高手。谢谢!
其实很简单的
$client = new soapclient('http://localhost/TestService/Service1.asmx?WSDL', true);
//要访问的webservice: http://localhost/TestService/Service1.asmx$param = array('str' => 'China');
//参数名:str 参数值:China$result = $client->call('HelloWorld', array('parameters' => $param), '', '', false, true,'document','encoded');
//方法名:HelloWorld文件下载
nusoap源文件: http://www.cnblogs.com/Files/coolstr/nusoap.zip
各种编码转换源文件: http://www.cnblogs.com/Files/coolstr/chinese.zip
http://www.dvbbs.net/tech/php/2006032927139.asp
这里面有个例子, 我按照这个例子 我把nusoap.php放在服务器上 include下。 把 soapclient.php ,soapserver.php,soapfunc.php 这三个文件 放在我得虚拟目录下(soap.test.com) 。 然后我执行 soapclient.php ,却没有 如例子中所说结果出来。 好像没有连接上web service 我打印的结果如下:
if you reverse 'this string will be reversed', you get 'Array'
if you add 5 and 14 you get Array
请问 ,是我部署有问题呢? 还是其他原因?请教高手。谢谢!