The content of this article is about debugging SOAP error messages under php5.5.12. It has a certain reference value. Now I share it with you. Friends in need can refer to it.
When debugging with soap today , the following error keeps appearing
{ "respcode": 202, "respmsg": "looks like we got no XML document", "data": "" }
I have found various methods but cannot solve it. My code is as follows:
Server side:
function __construct() { parent::__construct(); $this->load->model('baogaolist'); $this->server = new SoapServer(null, ['uri' => '']); } function checkreport() { $this->load->model('baogaolist'); $this->server->setObject($this->baogaolist); $this->server->handle(); }
Client call:
$url = $this->config->item('car_battery_check_url'); //获取信息地址 try { $a = new SoapClient(null, [ 'location' => $url . '/report/checkreport', 'uri' => '' ]); $detail = $a->get_detail($this->storeid, $check_id); } catch (SoapFault $e) { resp_msg(202,$e->getMessage()); }
In the php5.4.44 environment, the data can be successfully obtained, but in php5.5.12, errors will always be reported
Finally, in the php5.5.12 environment, complete the configuration uri and solve the problem
function __construct() { parent::__construct(); $this->load->model('baogaolist'); $this->server = new SoapServer(null, ['uri' => 'http://172.16.4.29:8000/index.php/report/checkreport']); }
try { $a = new SoapClient(null, [ 'location' => $url . '/report/checkreport', 'uri' => 'http://172.16.4.29:8000/index.php/report/checkreport' ]); $detail = $a->get_detail($this->storeid, $check_id); } catch (SoapFault $e) { resp_msg(202,$e->getMessage()); }
Only add specific addresses to both client and server
Related recommendations:
PHP implements WebService through SOAP
The above is the detailed content of Debugging SOAP error messages under php5.5.12. For more information, please follow other related articles on the PHP Chinese website!

在Web开发领域中,Web服务是一种非常重要的技术,它可以使不同的应用程序之间互相通信,从而构建更加复杂和强大的系统。在本文中,我们将深入探讨如何使用PHP和SOAP实现Web服务的调用和开发。SOAP(SimpleObjectAccessProtocol)是一种基于XML的协议,它用于在不同的应用程序之间进行信息交换。SOAP是一个重要的Web服务标

PHP和SOAP:如何实现远程过程调用(RPC)简介:近年来,随着分布式系统的兴起,远程过程调用(RemoteProcedureCall,RPC)在Web开发中被广泛采用。本文将介绍如何使用PHP和SOAP实现RPC,以及通过代码示例演示其用法。一、什么是远程过程调用(RPC)?远程过程调用(RemoteProcedureCall,RPC)是一种通信

PHP和SOAP:如何实现数据的同步和异步处理引言:在现代Web应用程序中,数据的同步和异步处理变得越来越重要。同步处理指的是一次只处理一个请求,并等待该请求完成后再处理下一个请求;而异步处理则是同时处理多个请求,并不等待某个请求的完成。在本文中,我们将介绍如何使用PHP和SOAP来实现数据的同步和异步处理。一、SOAP简介SOAP(SimpleObjec

随着互联网技术的不断发展,越来越多的企业级应用需要向其它应用程序提供接口以实现数据和业务的交互。在这种情况下,我们需要一种可靠的协议来传输数据并确保数据的完整性和安全性。SOAP(SimpleObjectAccessProtocol)就是一种基于XML的协议,可用于在Web环境中实现应用之间的通信。而PHP作为一种流行的Web编程语言,

如何使用PHP和SOAP实现数据的压缩和解压缩导言:在现代互联网应用中,数据的传输是非常常见的操作,然而,随着互联网应用的不断发展,数据量的增加和传输速度的要求,合理地使用数据压缩和解压缩技术成为了一个非常重要的话题。在PHP开发中,我们可以使用SOAP(SimpleObjectAccessProtocol)协议来实现数据的压缩和解压缩。本文将介绍如何

如何使用PHP和SOAP实现Web服务的部署和发布引言:在当今互联网时代,Web服务的部署和发布成为了一个非常重要的话题。PHP是一种流行的服务器端编程语言,而SOAP(SimpleObjectAccessProtocol)是一种XML协议,用于在Web服务之间进行通信。本文将向您介绍如何使用PHP和SOAP实现Web服务的部署和发布,并提供一些代码示

利用PHP和SOAP构建基于Web的应用程序的完整指南在当今互联网的时代,基于Web的应用程序已经成为了管理和交互数据的重要工具。PHP作为一种强大的开发语言,可以与其他技术进行无缝集成,而SOAP(SimpleObjectAccessProtocol)作为一种基于XML的通信协议,为我们提供了一种简单、标准和可扩展的方法来构建Web服务。本文将为您提

在实际成功渗透过程中,漏洞的利用都是多个技术的融合,最新技术的实践,本次渗透利用sqlmap来确认注入点,通过sqlmap来获取webshell,结合msf来进行ms16-075的提权,最终获取了目标服务器的系统权限。本文算是漏洞利用的一个新的拓展,在常规Nday提权不成功的情况下,结合msf进行ms16-075成功提权的一个经典案例。1.1.1扫描soap注入漏洞1.使用awvs中的webservicesscanner进行漏洞扫描打开awvs,选择webservicesscanner进行漏洞扫


Hot AI Tools

Undresser.AI Undress
AI-powered app for creating realistic nude photos

AI Clothes Remover
Online AI tool for removing clothes from photos.

Undress AI Tool
Undress images for free

Clothoff.io
AI clothes remover

AI Hentai Generator
Generate AI Hentai for free.

Hot Article

Hot Tools

SAP NetWeaver Server Adapter for Eclipse
Integrate Eclipse with SAP NetWeaver application server.

EditPlus Chinese cracked version
Small size, syntax highlighting, does not support code prompt function

Dreamweaver Mac version
Visual web development tools

Notepad++7.3.1
Easy-to-use and free code editor

VSCode Windows 64-bit Download
A free and powerful IDE editor launched by Microsoft
