doushi1900 2012-11-07 07:59
浏览 38

PHP的原始文本SOAP消息

I´m trying to do an integration between my own PHP application, and other external software which is 'waiting for' (listening) SOAP messages. But the key question on my situation is that this software which is listening for SOAP messages only accepts RAW contents and has no method which could be called, or Wsdl to be used.

Yes I know... it´s quite strange because with SOAP you usually should send a method request with some parameters, but in this case the only that I have is a URL where I should send with SOAP message that should contain only an string (formatted in a special way which is not a problem), and then this server will return to my PHP application another SOAP message that will contain a string. And that´s all.

Seems that in my case I can not use a PHP SOAP library because I have no method (or function) to call; the only thing that I have is a URL and a string that I should pass like a parameter. I´ve been thinking of using PHP sockets to create a basic SOAP message to that 'strange soap server', but I have no clue about how to do it, or how I woule create with PHP a way to keep my application waiting for the answer comming from that external server.

Thank you so much for your help in advance.

  • 写回答

1条回答 默认 最新

  • dousi2029 2012-11-07 08:10
    关注

    You might be best of by just making the WSDL on your own. It isn't the most trivial thing to do, but it is well documented so you should be able to figure it out.

    THere is no need to get the WSDL from the service you're sinding your requests to (it is rather better to have WSDL locally in some cases), so you just initialize the default SOAP client in PHP with that local WSDL, and off you go.

    评论

报告相同问题?

悬赏问题

  • ¥15 名为“Product”的列已属于此 DataTable
  • ¥15 安卓adb backup备份应用数据失败
  • ¥15 eclipse运行项目时遇到的问题
  • ¥15 关于#c##的问题:最近需要用CAT工具Trados进行一些开发
  • ¥15 南大pa1 小游戏没有界面,并且报了如下错误,尝试过换显卡驱动,但是好像不行
  • ¥15 没有证书,nginx怎么反向代理到只能接受https的公网网站
  • ¥50 成都蓉城足球俱乐部小程序抢票
  • ¥15 yolov7训练自己的数据集
  • ¥15 esp8266与51单片机连接问题(标签-单片机|关键词-串口)(相关搜索:51单片机|单片机|测试代码)
  • ¥15 电力市场出清matlab yalmip kkt 双层优化问题