pbootcms网站模板|日韩1区2区|织梦模板||网站源码|日韩1区2区|jquery建站特效-html5模板网

    <small id='0vNIi'></small><noframes id='0vNIi'>

  • <i id='0vNIi'><tr id='0vNIi'><dt id='0vNIi'><q id='0vNIi'><span id='0vNIi'><b id='0vNIi'><form id='0vNIi'><ins id='0vNIi'></ins><ul id='0vNIi'></ul><sub id='0vNIi'></sub></form><legend id='0vNIi'></legend><bdo id='0vNIi'><pre id='0vNIi'><center id='0vNIi'></center></pre></bdo></b><th id='0vNIi'></th></span></q></dt></tr></i><div class="htv5hvf" id='0vNIi'><tfoot id='0vNIi'></tfoot><dl id='0vNIi'><fieldset id='0vNIi'></fieldset></dl></div>
    <legend id='0vNIi'><style id='0vNIi'><dir id='0vNIi'><q id='0vNIi'></q></dir></style></legend>
      <bdo id='0vNIi'></bdo><ul id='0vNIi'></ul>
    <tfoot id='0vNIi'></tfoot>

      1. 肥皂:信封 SOAP-ENV:信封 PHP

        soap:Envelope SOAP-ENV:Envelope PHP(肥皂:信封 SOAP-ENV:信封 PHP)
        <tfoot id='K7eGl'></tfoot>
          <legend id='K7eGl'><style id='K7eGl'><dir id='K7eGl'><q id='K7eGl'></q></dir></style></legend>

                <bdo id='K7eGl'></bdo><ul id='K7eGl'></ul>

                  <small id='K7eGl'></small><noframes id='K7eGl'>

                • <i id='K7eGl'><tr id='K7eGl'><dt id='K7eGl'><q id='K7eGl'><span id='K7eGl'><b id='K7eGl'><form id='K7eGl'><ins id='K7eGl'></ins><ul id='K7eGl'></ul><sub id='K7eGl'></sub></form><legend id='K7eGl'></legend><bdo id='K7eGl'><pre id='K7eGl'><center id='K7eGl'></center></pre></bdo></b><th id='K7eGl'></th></span></q></dt></tr></i><div class="pzhdbpj" id='K7eGl'><tfoot id='K7eGl'></tfoot><dl id='K7eGl'><fieldset id='K7eGl'></fieldset></dl></div>
                    <tbody id='K7eGl'></tbody>
                  本文介紹了肥皂:信封 SOAP-ENV:信封 PHP的處理方法,對大家解決問題具有一定的參考價值,需要的朋友們下面隨著小編來一起學習吧!

                  問題描述

                  限時送ChatGPT賬號..

                  我正在嘗試使用 PHP 的內置soap 函數登錄API.我得到了這樣的結果.

                  I'm trying to login to an API using built-in soap functions of PHP. I got a result like this.

                  [LoginResult]=> false,
                  [ErrorMsg] => Login failed with the reason : The security object is invalid
                  

                  這是 API 提供者所要求的.

                  This is what required by the API provider.

                  <?xml version="1.0" encoding="utf-8"?>
                  <soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
                  <soap:Body>
                      <Login xmlns="http://tempuri.org/Example/Service1">
                            <objSecurity>
                                <WebProviderLoginId>test</WebProviderLoginId>
                                <WebProviderPassword>test</WebProviderPassword>
                                <IsAgent>false</IsAgent>
                            </objSecurity>
                            <OutPut />
                            <ErrorMsg />
                      </Login>
                  </soap:Body>
                  </soap:Envelope>
                  

                  &,這是我能夠使用函數生成的內容.

                  &, here is what I was able to produce using functions.

                  <?xml version="1.0" encoding="UTF-8"?>
                  <SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ns1="http://tempuri.org/Example/Service1">
                  <SOAP-ENV:Body>
                      <ns1:Login>
                          <objSecurity>
                               <WebProviderLoginId>test</WebProviderLoginId>
                               <WebProviderPassword>test</WebProviderPassword>
                               <IsAgent>false</IsAgent>
                          </objSecurity>
                          <OutPut/>
                          <ErrorMsg/>
                      </ns1:Login>
                  </SOAP-ENV:Body>
                  </SOAP-ENV:Envelope>
                  

                  這是我用來發送請求的代碼.

                  Here is the code I used to send the request.

                  <?php
                  class objSecurity {
                  function objSecurity($s, $i, $f)   {
                      $this->WebProviderLoginId = $s;
                      $this->WebProviderPassword = $i;
                      $this->IsAgent = $f;
                  }
                  }
                  
                  class nextObject {
                  function nextObject($objSecurity)   {
                      $this->objSecurity=$pobjSecurity;
                      $this->OutPut=NULL;
                      $this->ErrorMsg=NULL;
                  }
                  }
                  
                  $url    = 'http://example.com/sampleapi/test.asmx?WSDL';
                  $client = new SoapClient($url, array("soap_version" => SOAP_1_1,"trace" => 1));
                  $struct = new objSecurity('test', 'test', false);
                  $data   = new nextObject($struct);
                  $soapstruct2 = new SoapVar($data, SOAP_ENC_OBJECT);
                  print_r(
                     $client->__soapCall(
                         "Login",
                         array(new SoapParam($soapstruct2, "inputStruct"))
                     )
                  );
                  
                  echo $client->__getLastRequest();
                  
                  ?>
                  

                  這些是我發現的不同之處.

                  These are the differences I found.

                  在我的請求中缺少 xmlns:xsi.

                  要求以<soap:Envelope開頭,但我的請求以<SOAP-ENV:Envelope開頭.

                  Requirement starts with <soap:Envelope, But my request starts with <SOAP-ENV:Envelope.

                  我的請求中有一個額外的 xmlns:ns1.

                  There is an extra xmlns:ns1 in my request.

                  &函數名標簽以ns1:開頭.

                  & The function name tag starts with ns1:.

                  請幫助我將我的請求轉換為所需的格式.

                  Please help me to make my request into the required format.

                  我不太了解 SOAP,我使用的是 PHP 5.3.13 版和 CakePHP 2.3.0.對不起,我的英語不好.

                  I don't know much about the SOAP and I'm using PHP version 5.3.13 with CakePHP 2.3.0. Sorry, for my bad English.

                  推薦答案

                  這里是解決方案.:)

                  <?php
                  $url    = 'http://example.com/sampleapi/test.asmx?WSDL';
                  $client = new SoapClient($url, array("soap_version" => SOAP_1_1,"trace" => 1));
                  
                  $user_param = array (
                    'WebProviderLoginId' => "test",
                    'WebProviderPassword' => "test",
                    'IsAgent' => false
                  );
                  
                  $service_param = array (
                    'objSecurity' => $user_param,
                    "OutPut" => NULL,
                    "ErrorMsg" => NULL
                  );
                  
                  print_r(
                     $client->__soapCall(
                         "Login",
                         array($service_param)
                     )
                  );
                  
                  echo $client->__getLastRequest();
                  
                  ?>
                  

                  &請求是:

                  <?xml version="1.0" encoding="UTF-8"?>
                  <SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ns1="http://tempuri.org/Example/Service1">
                  <SOAP-ENV:Body>
                     <ns1:Login>
                         <ns1:objSecurity>
                             <ns1:WebProviderLoginId>test</ns1:WebProviderLoginId>
                             <ns1:WebProviderPassword>test</ns1:WebProviderPassword>
                             <ns1:IsAgent>false</ns1:IsAgent>
                         </ns1:objSecurity>
                     </ns1:Login>
                  </SOAP-ENV:Body>
                  </SOAP-ENV:Envelope>
                  

                  感謝這個鏈接.PHP SOAP 請求不正確

                  這篇關于肥皂:信封 SOAP-ENV:信封 PHP的文章就介紹到這了,希望我們推薦的答案對大家有所幫助,也希望大家多多支持html5模板網!

                  【網站聲明】本站部分內容來源于互聯網,旨在幫助大家更快的解決問題,如果有圖片或者內容侵犯了您的權益,請聯系我們刪除處理,感謝您的支持!

                  相關文檔推薦

                  enable SOAP on PHP(在 PHP 上啟用 SOAP)
                  Get received XML from PHP SOAP Server(從 PHP SOAP 服務器獲取接收到的 XML)
                  not a valid AllXsd value(不是有效的 AllXsd 值)
                  PHP SoapClient: SoapFault exception Could not connect to host(PHP SoapClient:SoapFault 異常無法連接到主機)
                  Implementation of P_SHA1 algorithm in PHP(PHP中P_SHA1算法的實現)
                  Sending a byte array from PHP to WCF(將字節數組從 PHP 發送到 WCF)
                    <tbody id='blATw'></tbody>
                • <i id='blATw'><tr id='blATw'><dt id='blATw'><q id='blATw'><span id='blATw'><b id='blATw'><form id='blATw'><ins id='blATw'></ins><ul id='blATw'></ul><sub id='blATw'></sub></form><legend id='blATw'></legend><bdo id='blATw'><pre id='blATw'><center id='blATw'></center></pre></bdo></b><th id='blATw'></th></span></q></dt></tr></i><div class="nnpdhdb" id='blATw'><tfoot id='blATw'></tfoot><dl id='blATw'><fieldset id='blATw'></fieldset></dl></div>

                    <tfoot id='blATw'></tfoot>
                      <bdo id='blATw'></bdo><ul id='blATw'></ul>

                      <small id='blATw'></small><noframes id='blATw'>

                    • <legend id='blATw'><style id='blATw'><dir id='blATw'><q id='blATw'></q></dir></style></legend>

                            主站蜘蛛池模板: 商用绞肉机-熟肉切片机-冻肉切丁机-猪肉开条机 - 广州市正盈机械设备有限公司 | 真石漆,山东真石漆,真石漆厂家,真石漆价格-山东新佳涂料有限公司 | 科研ELISA试剂盒,酶联免疫检测试剂盒,昆虫_植物ELISA酶免试剂盒-上海仁捷生物科技有限公司 | 动库网动库商城-体育用品专卖店:羽毛球,乒乓球拍,网球,户外装备,运动鞋,运动包,运动服饰专卖店-正品运动品网上商城动库商城网 - 动库商城 | 储气罐,真空罐,缓冲罐,隔膜气压罐厂家批发价格,空压机储气罐规格型号-上海申容压力容器集团有限公司 | 全自动包装秤_全自动上袋机_全自动套袋机_高位码垛机_全自动包装码垛系统生产线-三维汉界机器(山东)股份有限公司 | 润滑油加盟_润滑油厂家_润滑油品牌-深圳市沃丹润滑科技有限公司 琉璃瓦-琉璃瓦厂家-安徽盛阳新型建材科技有限公司 | EDLC超级法拉电容器_LIC锂离子超级电容_超级电容模组_软包单体电容电池_轴向薄膜电力电容器_深圳佳名兴电容有限公司_JMX专注中高端品牌电容生产厂家 | 喷砂机厂家_自动除锈抛丸机价格-成都泰盛吉自动化喷砂设备 | 定制奶茶纸杯_定制豆浆杯_广东纸杯厂_[绿保佳]一家专业生产纸杯碗的厂家 | 全钢实验台,实验室工作台厂家-无锡市辰之航装饰材料有限公司 | 舞台木地板厂家_体育运动木地板_室内篮球馆木地板_实木运动地板厂家_欧氏篮球地板推荐 | 东莞螺丝|东莞螺丝厂|东莞不锈钢螺丝|东莞组合螺丝|东莞精密螺丝厂家-东莞利浩五金专业紧固件厂家 | 螺旋压榨机-刮泥机-潜水搅拌机-电动泥斗-潜水推流器-南京格林兰环保设备有限公司 | pbt头梳丝_牙刷丝_尼龙毛刷丝_PP塑料纤维合成毛丝定制厂_广州明旺 | 江苏远邦专注皮带秤,高精度皮带秤,电子皮带秤研发生产 | 快速卷帘门_硬质快速卷帘门-西朗门业 | 北京网站建设|北京网站开发|北京网站设计|高端做网站公司 | 仪器仪表网 - 永久免费的b2b电子商务平台 | 一体化隔油提升设备-餐饮油水分离器-餐厨垃圾处理设备-隔油池-盐城金球环保产业发展有限公司 | PC构件-PC预制构件-构件设计-建筑预制构件-PC构件厂-锦萧新材料科技(浙江)股份有限公司 | 玉米深加工机械,玉米加工设备,玉米加工机械等玉米深加工设备制造商-河南成立粮油机械有限公司 | 艾默生变频器,艾默生ct,变频器,ct驱动器,广州艾默生变频器,供水专用变频器,风机变频器,电梯变频器,艾默生变频器代理-广州市盟雄贸易有限公司官方网站-艾默生变频器应用解决方案服务商 | 铝扣板-铝方通-铝格栅-铝条扣板-铝单板幕墙-佳得利吊顶天花厂家 elisa试剂盒价格-酶联免疫试剂盒-猪elisa试剂盒-上海恒远生物科技有限公司 | 篷房|仓储篷房|铝合金篷房|体育篷房|篷房厂家-华烨建筑科技官网 知名电动蝶阀,电动球阀,气动蝶阀,气动球阀生产厂家|价格透明-【固菲阀门官网】 | 中高频感应加热设备|高频淬火设备|超音频感应加热电源|不锈钢管光亮退火机|真空管烤消设备 - 郑州蓝硕工业炉设备有限公司 | 设定时间记录电子秤-自动累计储存电子秤-昆山巨天仪器设备有限公司 | 电机铸铝配件_汽车压铸铝合金件_发动机压铸件_青岛颖圣赫机械有限公司 | 一体化污水处理设备,一体化污水设备厂家-宜兴市福源水处理设备有限公司 | UV固化机_UVLED光固化机_UV干燥机生产厂家-上海冠顶公司专业生产UV固化机设备 | 365文案网_全网创意文案句子素材站 | 溶氧传感器-pH传感器|哈美顿(hamilton) | 浙江自考_浙江自学考试网 | 过跨车_过跨电瓶车_过跨转运车_横移电动平车_厂区转运车_无轨转运车 | 黄石妇科医院_黄石东方女子医院_黄石东方妇产医院怎么样 | 冲击式破碎机-冲击式制砂机-移动碎石机厂家_青州市富康机械有限公司 | 氧化锆纤维_1800度高温退火炉_1800度高温烧结炉-南京理工宇龙新材料股份有限公司 | 苏州教学设备-化工教学设备-环境工程教学模型|同科教仪 | 贵州自考_贵州自学考试网 | 医学动画公司-制作3d医学动画视频-医疗医学演示动画制作-医学三维动画制作公司 | 广州活动策划公司-15+年专业大型公关活动策划执行管理经验-睿阳广告 |