Jump to content

what does -> mean?


your_twin

Recommended Posts

If i have this line of code:

[color=red]$params->def( 'scrolling', 'auto' );[/color]

i understand that
       
            -[b]$params[/b] is a variable

            -[b]def()[/b] is a function of some sort

            -what does the [b]->[/b] operator do or mean?  ???

i assume its an operator but i cant find it in the php manual @ php.net
Link to comment
https://forums.phpfreaks.com/topic/28838-what-does-mean/
Share on other sites

i cant give you the best definition but here it goes:

$params is a class. and the def() is a function inside of that class. This is called OOP (object orientated programming). To call a function inside of a class you must use the ->

I think thats it, just look up OOP somewhere to learn more.
Link to comment
https://forums.phpfreaks.com/topic/28838-what-does-mean/#findComment-132032
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.