07-14-2008, 03:26 PM
|
#12 (permalink)
|
|
The Acquainted
Join Date: Sep 2007
Location: Leeds, UK
Posts: 141
Thanks: 6
|
Quote:
Originally Posted by Tanax
Why are you using self::$localhost and self:: all over the place?
If you're using PHP5, then you have use a static variable, and you aren't, so.. you need to use $this->localhost etc.
|
Quote:
Originally Posted by xenon
Because you can't access class constants and/or static properties using the $this keyword.
|
Urm, yeah, what he said ^
I'd always used define and remembered once I saw a different way of doing that with OOP, ala const so seeing as I love being different, I did it that way :P
__________________
Not quite a n00b...
|
|
|
|