0
我應該在服務器收到我發送的字符串後收到一個名爲「D」的變量。我如何獲得它以接收服務器響應消息?soap curl request works but not does not
$soapme = curl_init();
curl_setopt($soapme, CURLOPT_URL, $url);
curl_setopt($soapme, CURLOPT_CONNECTTIMEOUT, 10);
curl_setopt($soapme, CURLOPT_TIMEOUT, 10);
curl_setopt($soapme, CURLOPT_RETURNTRANSFER, true);
curl_setopt($soapme, CURLOPT_SSL_VERIFYPEER, false);
curl_setopt($soapme, CURLOPT_SSL_VERIFYHOST, false);
curl_setopt($soapme, CURLOPT_POST, true);
curl_setopt($soapme, CURLOPT_POSTFIELDS, $post_string);
curl_setopt($soapme, CURLOPT_HTTPHEADER, array('Content-Type: text/xml; charset=utf-8', 'Content-Length: '.strlen($post_string)));
curl_setopt($soapme, CURLOPT_USERPWD, $user . ":" . $password);
curl_setopt($soapme, curlOPT_VERBOSE, 1);
curl_exec($soapme);
我發現我得到一個1,當我不使用ReturnTransfers結果。這是什麼意思?
其空白。服務器管理員(單獨的公司)說他收到了我發送的消息,但我仍然得到一個空白的迴應。 – tdjfdjdj
嘗試從命令行運行curl,看看你回來:'curl -v -D「your_post_string」http:// endpoint' –
是否有一個用於windows的curl.exe?我不在linux上 – tdjfdjdj