Page 1 of 1
$config = $db->get_row($sql);
Posted: Tue Sep 09, 2008 7:22 pm
by davidshq
What does -> mean? I get that $config is a variable being set equal to $db? But does -> mean like an action is taking place? If someone could point me to some docs. on this or an explanation, it would be appreciated.
Dave.
Re: $config = $db->get_row($sql);
Posted: Wed Sep 10, 2008 2:29 am
by shaneiadt
I can't find anything on php.net at first glance, but the "->" operator is used when dealing with objects, assessing object variables and methods. Take a look at the link below if you like
http://ie2.php.net/zend-engine-2.php
P.S. the code in question, $db -> get_row($sql); is invoking the get_row() method defined in the $db object type. Not sure if this is what you were asking for or not!
Re: $config = $db->get_row($sql);
Posted: Wed Sep 10, 2008 11:04 am
by davidshq
yes, exactly what i was looking for. thx!
dave.