[PHP] Re: overwrite private class members in php5?

2005-08-05 Thread Norbert Wenzel
Matthew Weier O'Phinney wrote: * Norbert Wenzel [EMAIL PROTECTED]: Hi, I've done something like this: class MyClass { private $var; function __construct($value) { $this-var = $value; } public function printVar() { echo($this-var); } } $object = new MyClass('1');

[PHP] Re: overwrite private class members in php5?

2005-08-04 Thread Matthew Weier O'Phinney
* Norbert Wenzel [EMAIL PROTECTED]: Hi, I've done something like this: class MyClass { private $var; function __construct($value) { $this-var = $value; } public function printVar() { echo($this-var); } } $object = new MyClass('1'); $object-printVar(); //

[PHP] Re: overwrite private class members in php5?

2005-07-29 Thread Norbert Wenzel
Norbert Wenzel wrote: public function printVar() { echo($this-var); } I have to do a little correction, i wrote $this-$var to see the variable, otherwise i don't see anything. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php