note 22373 added to keyword.parent
| From: | gibby at onebox dot com | Date: | Sat, 15 Jun 2002 08:25:17 +0000 |
| Subject: | note 22373 added to keyword.parent | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-31883@lists.php.net to get a copy of this message | ||
Regarding the example above, I believe the result is misleading, if you're inferring that the
$this in Class One's OneDo method refers to One.
If that wasn't your conclusion, then my apologies-- I misunderstood you.
But if it was, it might save trouble to note that $this is effectively an alias for $o (a Class Two
object). $v is available to $o, and that's how it's being picked up. $this is $o in that
example, not One (One is a class and has no implementation).
I hope that's helpful.
Brad
--
http://www.php.net/manual/en/keyword.parent.php
http://master.php.net/manage/user-notes.php?action=edit+22373
http://master.php.net/manage/user-notes.php?action=delete+22373
http://master.php.net/manage/user-notes.php?action=reject+22373