Nusoap 如何使用现有的 WSDL?
所以我有一个 WSDL 作为肥皂服务的文档。我需要完全按照定义实现此服务,并且我不想使用 nusoap 重写 wsdl。有没有办法告诉对象 nusoap_server = newsoap_server();使用现有的 wsdl,然后实现现有 wsdl 中的功能?
谢谢
so I have a WSDL I've been giving as documentation for a soap service. I need to implement this service exactly as defined and I don't want to rewrite the wsdl using nusoap. Is there a way to tell the object nusoap_server = new soap_server(); to use an existing wsdl and then implement the functions from the existing wsdl?
thanks
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
$WSDL = '/path/to/wsdl/file';
$nusoap_server = 新soap_server($WSDL);
唯一的问题是 nusoap 可能无法正确创建响应,但它将托管 wsdl 文件。
我必须自定义我的 xml 响应。
您可以告诉 nusoap 这样做,但您需要修改库。
上面的代码位于 nusoap 库中,您可以看到 $this->methodreturnisliteralxml
如果将其设置为 true,那么您可以自定义从为 nusoap 定义的函数返回的 xml 来处理肥皂请求。
对我来说 nusoap 已经过时了。
我认为我不会在新项目中再次使用 nusoap。
$WSDL = '/path/to/wsdl/file';
$nusoap_server = new soap_server($WSDL);
The only problem with this is that nusoap may not create the response correctly, but it will host the wsdl file.
I had to customize my xml responses.
Which you can tell nusoap to do but you will need to modify the library.
This above code is in the nusoap library as you can see $this->methodreturnisliteralxml
If you set that to true then you can customize the xml you return from the function you define for nusoap to handle the soap request.
To me nusoap seams to be out of date.
I do not think I would use nusoap again for new projects.