php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #27838 SoapServer->setClass does not trigger __construct(), but only ClassName()
Submitted: 2004-04-02 09:11 UTC Modified: 2004-04-12 17:55 UTC
Votes:3
Avg. Score:4.0 ± 0.8
Reproduced:2 of 2 (100.0%)
Same Version:1 (50.0%)
Same OS:0 (0.0%)
From: ron at xit dot nl Assigned:
Status: No Feedback Package: Scripting Engine problem
PHP Version: 5.0.0RC1 OS: Debian
Private report: No CVE-ID: None
Have you experienced this issue?
Rate the importance of this bug to you:

 [2004-04-02 09:11 UTC] ron at xit dot nl
Description:
------------
Hi,

When I use the SetClass method in my SoapServer object, it only triggers a constructor with the name of the class: ClassName() and not __construct. It happens when I don't even have a constructor called ClassName(), so it's not a problem of the order in which the Zend Engine looks for constructors. It simply always ignores __construct().

Reproduce code:
---------------
class SoapHandler
{
  function __construct($param)
  {
    die($param);
  }
}

$soap = new SoapServer(NULL, array("uri" => "urn:myurn"));
$soap->setClass("SoapHandler", "myparam");


Expected result:
----------------
output:

myparam

Actual result:
--------------
no output

rename the __construct to SoapHandler() and it will work as expected

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2004-04-07 04:36 UTC] sniper@php.net
Please try using this CVS snapshot:

  http://snaps.php.net/php5-latest.tar.gz
 
For Windows:
 
  http://snaps.php.net/win32/php5-win32-latest.zip


 [2004-04-12 17:55 UTC] sniper@php.net
No feedback was provided. The bug is being suspended because
we assume that you are no longer experiencing the problem.
If this is not the case and you are able to provide the
information that was requested earlier, please do so and
change the status of the bug back to "Open". Thank you.


 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Thu Apr 25 02:01:30 2024 UTC