Justtechjobs.com Find a programming school near you






Online Campus Both


php-general | 2001062

[PHP] OOP From: Andrew Kirilenko (icedwork <email protected>)
Date: 06/23/01

Hello!

Is it possible to do normal inheritance on PHP?
I've following code:

--->

class one
{
        function one()
        {
                echo "one ";
        }
}

class two extends one
{
        function two()
        {
                echo "two ";
        }
}

class three extends two
{
        function three()
        {
                echo "three";
        }
}

$foo = new three();

<---

And the output of this programm is "three", but not "one two three" :(

Best regards,
Andrew Kirilenko,
Seniour Programmer / System Administrator,
Internet Service.

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: php-general-unsubscribe <email protected>
For additional commands, e-mail: php-general-help <email protected>
To contact the list administrators, e-mail: php-list-admin <email protected>