Re: $this - >

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



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.


--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux