php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #44117 SOAP fault, appears that function doesn't exist
Submitted: 2008-02-14 05:39 UTC Modified: 2008-02-14 13:56 UTC
From: matt at warnockinc dot com Assigned:
Status: Not a bug Package: Reproducible crash
PHP Version: 5.2.5 OS: Redhat EL5 64-bit
Private report: No CVE-ID: None
 [2008-02-14 05:39 UTC] matt at warnockinc dot com
Description:
------------
I am writing a script and keep getting an error.  It appears that the function "logout" doesn't exist, however it is in the server, and in the WSDL.  I removed everything but the function, and can reproduce the error

Reproduce code:
---------------
server:

$server = new SoapServer( 'ws.wsdl', array('uri' => "urn://www.herong.home/res")
	);
$server->SetClass('ws');
$server->handle();

class ws
{
	/**
	* logout method
	*
	* @param string $sessionkey sessionKey
	* @return string status status
	*/
	function logout ( $sessionkey )
	{
             return "true";
	}
}

Client:

   $client = new SoapClient(null, array(
      'location' => "http://localhost/testserver.php",
      'uri'      => "urn://www.herong.home/req",
      'trace'    => 1 ));

	$return = $client->__soapCall("logout",array("04cbf12ab33ccf7710c24ef7f59699393371f319"));
	print_r( $return );

Expected result:
----------------
i should see "true"

Actual result:
--------------
Fatal error: Uncaught SoapFault exception: [SOAP-ENV:Server] Procedure 'logout' not present in /home/user/public_html/Dunbar/testclient.php:9 Stack trace: #0 /home/user/public_html/Dunbar/testclient.php(9): SoapClient->__soapCall('logout', Array) #1 {main} thrown in /home/user/public_html/Dunbar/testclient.php on line 9

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2008-02-14 13:56 UTC] matt at warnockinc dot com
appears to be a problem in the WSDL file.  sorry for the inconvenience.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Thu Apr 18 16:01:29 2024 UTC