note 72289 added to keyword.parent
| From: | riku dot tuominen at benchmarking dot fi | Date: | Thu, 11 Jan 2007 16:41:38 +0000 |
| Subject: | note 72289 added to keyword.parent | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-121558@lists.php.net to get a copy of this message | ||
But if we are not using extends but instead want to know who instantiated the class.
class A {
foo(){
// aviously this do not work but how would need to be changed
echo parent::foo;
}
class B {
$foo = 'test';
myObject = new A();
myObject.foo();
}
----
Server IP: 62.237.7.3
Probable Submitter: 84.230.187.192
----
Manual Page -- http://www.php.net/manual/en/keyword.parent.php
Edit -- https://master.php.net/note/edit/72289
Del: integrated -- https://master.php.net/note/delete/72289/integrated
Del: useless -- https://master.php.net/note/delete/72289/useless
Del: bad code -- https://master.php.net/note/delete/72289/bad+code
Del: spam -- https://master.php.net/note/delete/72289/spam
Del: non-english -- https://master.php.net/note/delete/72289/non-english
Del: in docs -- https://master.php.net/note/delete/72289/in+docs
Del: other reasons-- https://master.php.net/note/delete/72289
Reject -- https://master.php.net/note/reject/72289
Search -- https://master.php.net/manage/user-notes.php