I have following problem:

$container = new ccontainer();

class ccontainer
    function ccontainer()

    function init()
        $this->test1 = new ctest(&$this);
        $this->test2 = new ctest(&$this);

class ctest
    function ctest(&$owner)
        $this->owner = $owner;

    function foo()
        echo "test!<br>";

Output of this script is:
Fatal error: Call to a member function on a non-object in c:\www\a.php on
line 8

How to solve this problem???

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

PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]

Reply via email to