如何在返回DataSet的php中使用WCF服务? [英] How to consume WCF service in php that returns DataSet?

查看:69
本文介绍了如何在返回DataSet的php中使用WCF服务?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述



我发布了WCF服务,其中包含多个返回DataSet的方法。

我在windows应用程序中使用此服务正常工作。

现在我想在php应用程序中使用这个wcf服务。

下面是GetCancelledOrderList()方法的示例代码,它接受两个参数并返回DataSet作为结果。



$ USERNAME_TEST ='TESTAFF';

$ PASSWORD_TEST ='T @ 4S4%T';

$ WSDL_TEST = serviceurl?wsdl;



$ client = new SoapClient($ WSDL_TEST);

// print_r($ client-> __ getFunctions( ));

$ result = $ client-> GetCancelledOrderList(array('userName'=> $ USERNAME_TEST,'password'=> $ PASSWORD_TEST));

var_dump( $结果);

print_r($ result);

?>



我无法打印包含清单订单编号的回复结果。

请帮我解决这个问题。

提前谢谢。

解决方案

USERNAME_TEST ='TESTAFF';

PASSWORD_TEST ='T @ 4S4%T';


WSDL_TEST =serviceurl?wsdl;



Hi,
I have published WCF service which contains multiple methods that returns DataSet.
I have consumed this service in windows application working fine.
Now I would like to consume this wcf service in php application.
Below is the sample code for GetCancelledOrderList() method that accepts two parameters and returns the DataSet as a result.

$USERNAME_TEST = 'TESTAFF';
$PASSWORD_TEST = 'T@4S4%T';
$WSDL_TEST = "serviceurl?wsdl";

$client = new SoapClient($WSDL_TEST);
//print_r($client->__getFunctions());
$result =$client->GetCancelledOrderList(array('userName'=>$USERNAME_TEST, 'password'=>$PASSWORD_TEST));
var_dump($result);
print_r($result);
?>

I am not able to print response result that contains list order order number.
Please help me to sortout this issue.
Thanks in advance.

解决方案

USERNAME_TEST = 'TESTAFF';


PASSWORD_TEST = 'T@4S4%T';


WSDL_TEST = "serviceurl?wsdl";


这篇关于如何在返回DataSet的php中使用WCF服务?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆