I have been using PHP for a while, but I often end up reusing old code and rarely learning new stuff.
I have seen on a lot of code (included the PHPBB code) that in PHP code sometimes look like:
Code: Select all
$variable->somethingCode: Select all
$handle = db_connect();
$pages_sql = 'select * from table';
$result = $handle->query($pages_sql);Can someone tell me:
(a) what does the -> do ?
(b) what is the concept called?
(c) can you give me a brief example?
Huge thanks
Hamish