|   | php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login | 
| 
 PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits              [2009-03-05 22:38 UTC] starson dot hochschild at mtginfo dot com
  [2010-06-20 21:29 UTC] felipe@php.net
 
-Status: Open
+Status: Feedback
  [2010-06-20 21:29 UTC] felipe@php.net
  [2013-02-18 00:33 UTC] php-bugs at lists dot php dot net
 | |||||||||||||||||||||||||||||||||
|  Copyright © 2001-2025 The PHP Group All rights reserved. | Last updated: Fri Oct 31 03:00:01 2025 UTC | 
Description: ------------ I just upgraded from 5.1.6 to 5.2.9. Calling __construct from an extended SoapClient class via variable used to work but this is no longer the case. Somehow it gets picked up by __call now. Calling __construct from an extended SoapClient class explicitly still works. Calling SoapClient from an extended SoapClient class via variable still works. I did not include an example for this, though. This is definitely not a show-stopper but it would be nice to have consistency. I haven't noticed this with any other classes, but then again using a variable to call __construct isn't exactly common. Reproduce code: --------------- <?php class SoapClientExplicit extends SoapClient { public function misSoap($wsdl, $options = array()) { parent::__construct($wsdl, $options); } } class SoapClientVariable extends SoapClient { public function misSoap($wsdl, $options = array()) { $function = __FUNCTION__; parent::$function($wsdl, $options); } } echo __LINE__."\n"; $sce = new SoapClientExplicit('http://example.com/ns/func?wsdl'); echo __LINE__."\n"; $scv = new SoapClientVariable('http://example.com/ns/func?wsdl'); echo __LINE__."\n"; ?> Expected result: ---------------- 13 15 17 Actual result: -------------- 13 15 Fatal error: Uncaught SoapFault exception: [Client] Error finding "uri" property in /path/to/script.php:10 Stack trace: #0 [internal function]: SoapClient->__call('__construct', Array) #1 /path/to/script.php(10): SoapClient->__construct('http://example...', Array) #2 /path/to/script.php(16): SoapClientVariable->__construct('http://example...', Array) #3 {main} thrown in /path/to/script.php on line 10