OZONE Asylum
Forums
Server-Side Scripting - Oh my!
What's -> in php do?
This page's ID:
27910
Search
QuickChanges
Forums
FAQ
Archives
Register
Edit Post
Who can edit a post?
The poster and administrators may edit a post. The poster can only edit it for a short while after the initial post.
Your User Name:
Your Password:
Login Options:
Remember Me On This Computer
Your Text:
Insert Slimies »
Insert UBB Code »
Close
Last Tag
|
All Tags
UBB Help
Two notes: 1) You can use reference points for functions and variables, and consecutively. e.g.: $this->user->get_profile(); Just remember that one of the benefits of OOP is encapsulation. Also, check out the parts of man php on[url=http://www.php.net/manual/en/language.oop5.magic.php] Magic Methods [/url] like __get() and __set(), where you can override reference points. 2) There's also ::, which is the [url=http://www.php.net/manual/en/language.oop5.paamayim-nekudotayim.php]Scope Resolution Operator[/url]. This is mainly for things that don't require an instance. e.g. $plural_word = StringHelper::pluralize($word); It tells PHP which scope in which to look (and is therefore aptly named). Use it when the function doesn't need an instance or instance variables to perform a method. Finally, a note for Tiberius (from a previous discussion), there are in fact[url=http://www.php.net/manual/en/language.oop5.interfaces.php] actual interfaces in PHP5[/url]. Who knew? ;) Cheers, DC
Loading...
Options:
Enable Slimies
Enable Linkwords
« Backwards
—
Onwards »
Maximum Security
OZONE
DHTML/Javascript
Server-Side Scripting - Oh my!
CSS - DOM - XHTML - XML - XSL - XSLT
Stupid Basic HTML
Visual Therapy
Photoshop
Photoshop Pong, Anyone?
***WARNING*** BIG SIG APPROACHING
Photography
3D Modelling & Rendering
Multimedia/Animation
Print Graphics
Holding Pens
Philosophy and other Silliness
Outpatient Counseling
Site reviews!
Mad Scientists' Laboratory
Getting to know the Grail