Re: $this - >
| From: | Klaus Reimer | Date: | Fri, 03 Dec 2004 07:16:13 +0000 |
| Subject: | Re: $this - > | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-203408@lists.php.net to get a copy of this message | ||
R. Van Tassel wrote:
Can someone please point me to the php documentation where it explains $this - >1. It must be "$this->" and not "$this - >". 2. Documentation can be found here: http://de.php.net/manual/en/language.oop.php
What is the symbol "- >" and is $this something only used in classes?Yes. Inside a method you can use "$this" to reference the current object in which the method was called. The "->" operator is not specific to "$this". It is generelly used to call methods or access properties of an object.