Bug #2310 Updated: Constructor not being called
| From: | sander@php.net | Date: | Sun, 16 Jun 2002 12:58:23 +0000 |
| Subject: | Bug #2310 Updated: Constructor not being called | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-10698@lists.php.net to get a copy of this message | ||
ID: 2310
Updated by: sander@php.net
Reported By: bobval@zedak.com
-Status: Open
+Status: Bogus
Bug Type: Other
Operating System: Red Hat Linux
PHP Version: 3.0.12
New Comment:
Thank you for taking the time to report a problem with PHP.
Unfortunately, PHP 3 is no longer supported. Please download
the latest version of PHP 4 from http://www.php.net/downloads.php
If you are able to reproduce the bug with one of the latest
versions of PHP, please change the PHP version on this bug report
to the version you tested and change the status back to "Open".
Again, thank you for your continued support of PHP.
Previous Comments:
------------------------------------------------------------------------
[1999-09-15 16:21:22] bobval@zedak.com
I have a class B that extends class A
The constructor for Class never gets called.
class A {
A() {
print("Hi from Class A");
}
Nothing() {
print("Class A - Nothing");
}
}
class B extends A {
B() {
print("Hi from Class B");
}
}
$ClassB = new B;
$ClassB->Nothing();
When I create a class B the B constructor gets called but NOT the class
A constructor. How do I get the A constructor to be called as well?
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=2310&edit=1