Re: [PHP] Basics of OOP
On Tue, 2008-09-09 at 20:09 +0100, Ben Stones wrote: > Hi, > > The following bit of code doesn't output anything: > > class output { > var $text; > function outputText() { > $this->text = "Hello World"; > echo $this->text; > } > } > >
[PHP] Basics of OOP
Hi, The following bit of code doesn't output anything: text = "Hello World"; echo $this->text; } } $class = new output(); $class->outputText; ?> As well as the following code: text; } } $class = new output(); $class->outputText; ?> Am I doi