From db9ed0cf564b9cd806ea44b0a39fa9925869aa27 Mon Sep 17 00:00:00 2001 From: webpwnized Date: Tue, 8 Oct 2024 19:23:12 -0400 Subject: [PATCH] 2.11.22 Update web service --- src/webservices/soap/ws-hello-world.php | 10 +++++----- src/webservices/soap/ws-lookup-dns-record.php | 4 ++-- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/src/webservices/soap/ws-hello-world.php b/src/webservices/soap/ws-hello-world.php index d9ec1a9..0b36c67 100755 --- a/src/webservices/soap/ws-hello-world.php +++ b/src/webservices/soap/ws-hello-world.php @@ -4,13 +4,13 @@ require_once './lib/nusoap.php'; // Create the SOAP server instance - $server = new soap_server(); + $lSOAPWebService = new soap_server(); // Initialize WSDL (Web Service Definition Language) support - $server->configureWSDL('hellowsdl', 'urn:hellowsdl'); + $lSOAPWebService->configureWSDL('hellowsdl', 'urn:hellowsdl'); // Register the "hello" method to expose as a SOAP function - $server->register( + $lSOAPWebService->register( 'hello', // method name array('name' => 'xsd:string'), // input parameter array('return' => 'xsd:string'), // output parameter @@ -48,9 +48,9 @@ function hello($name) { // Handle the SOAP request with error handling try { // Process the incoming SOAP request - $server->service(file_get_contents("php://input")); + $lSOAPWebService->service(file_get_contents("php://input")); } catch (Exception $e) { // Send a fault response back to the client - $server->fault('Server', "SOAP Service Error: " . $e->getMessage()); + $lSOAPWebService->fault('Server', "SOAP Service Error: " . $e->getMessage()); } ?> diff --git a/src/webservices/soap/ws-lookup-dns-record.php b/src/webservices/soap/ws-lookup-dns-record.php index 9c40f87..31c8632 100755 --- a/src/webservices/soap/ws-lookup-dns-record.php +++ b/src/webservices/soap/ws-lookup-dns-record.php @@ -117,9 +117,9 @@ function lookupDNS($pTargetHost) { // Handle the SOAP request with error handling try { // Process the incoming SOAP request - $server->service(file_get_contents("php://input")); + $lSOAPWebService->service(file_get_contents("php://input")); } catch (Exception $e) { // Send a fault response back to the client - $server->fault('Server', "SOAP Service Error: " . $e->getMessage()); + $lSOAPWebService->fault('Server', "SOAP Service Error: " . $e->getMessage()); } ?>