note 22236 deleted from language.oop by jmcastagnetto

From: Date: Fri, 04 Oct 2002 00:27:28 +0000
Subject: note 22236 deleted from language.oop by jmcastagnetto
References: 1  Groups: php.notes 
Request: Send a blank email to php-notes+get-37643@lists.php.net to get a copy of this message
Just tried finding out some solution for the following code, not working: [example] <? class bar { var $name; function getName() { echo $this->name; } } class foo { var $bar_field; function setElement ( $newBar ) { $this->bar_field = $newBar; } function getElement () { return $this->bar_field; } } $test_bar = new bar; $test_foo = new foo; $test_foo->setElement($test_bar); // NOT WORKING $test_foo->getElement()->getName(); // NOT WORKING ?> Found nothing documentated since now, anyone knows a friendly or maybe even clean solution??

« previous php.notes (#37643) next »