sambib Posted September 24, 2006 Share Posted September 24, 2006 [b]$CFG->[/b]wwwroot = 'http://site.local';i can't find -> anywhere in my two php books or online to tell me what this piece of code is doing...I'll take a guess that it's seeting a variable to 'http://site.local' but don't really understand why the -> is used or what it's there for...?thanks Quote Link to comment Share on other sites More sharing options...
Barand Posted September 24, 2006 Share Posted September 24, 2006 You are reading the wrong books. Try the php manualhttp://www.php.net/manual/en/language.oop.php Quote Link to comment Share on other sites More sharing options...
yonta Posted September 24, 2006 Share Posted September 24, 2006 That has to do with object-oriented coding. An object is mainly a name for an instance of a class.In this case, $CFG is an object that has a property ('wwwroot'), and this property is being set to 'http://site.local' .Somewhere in your script(s) there's probably a '$CFG = new NameofClass();' line. Find it and then check the class.For a better understanding, google php oop tutorial and read some or check here [url=http://www.phpfreaks.com/tutorials/48/0.php]http://www.phpfreaks.com/tutorials/48/0.php [/url] Quote Link to comment Share on other sites More sharing options...
sambib Posted September 25, 2006 Author Share Posted September 25, 2006 thanks guys, just what I wanted....! Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.