Re: Bug #1229: Bug 1109 revisited WRT class and more than one var

From: Date: Fri, 12 Mar 1999 07:40:48 +0000
Subject: Re: Bug #1229: Bug 1109 revisited WRT class and more than one var
References: 1  Groups: php.dev 
Request: Send a blank email to php-dev+get-4587@lists.php.net to get a copy of this message
On Thu, 11 Mar 1999, you wrote: > From: btribit@sungard.com > Operating system: Linux 2.2.2 > PHP version: 3.0.7 > PHP Bug Type: Other > Bug description: Bug 1109 revisited WRT class and more than one var > I am not sure about this but when I use $this-> I don't put the second $ in. Maybe try it with $this->va instead of $this->$va because $ denotes that everything following is a variable Timothy > <HTML> > <PRE> > <?php > class test { > var $va; > var $vb; > > function init() { > $this->$va = 0; > $this->$vb = 0; > echo $this->$va; > echo $this->$vb; > } > function test1() { > $this->$va = 10; > $this->$vb = 15; > print $this->$va; > print $this->$vb; > } > function test2() { > $this->$va = 15; > $this->$vb = 10; > print $this->$va; > print $this->$vb; > } > } > $testing = new test; > $testing->init(); > $testing->test1(); > $testing->test2(); > ?> > </PRE> > </HTML> > > I compilied this as an apache 1.3.4 module with oracle support. php3.ini not relevant, not > using it. The only thing I can offer is that php appears that it is having a problem keeping track > of more than one variable. This should provide a clue as to what is going on. > > > > -- > PHP Development Mailing List http://www.php.net/ > To unsubscribe send an empty message to php-dev-unsubscribe@lists.php.net > For help: php-dev-help@lists.php.net -- Timothy Whitfield AMC Internet Services American Metrocomm Corporation Phone 228-872-0003 Fax 228-435-4388 -- PHP Development Mailing List http://www.php.net/ To unsubscribe send an empty message to php-dev-unsubscribe@lists.php.net For help: php-dev-help@lists.php.net

« previous php.dev (#4587) next »