> I'm having problems figuring this out. This first way gives me a 'Fatal > Error: Cannot use [] for reading in class.php on line xx' > > class myClass > { > var $arr = array(); > > function add_something( $value ) > { > $this->$arr[] = $value; // this is the line causing the error
$this->arr[] = $value ---John W. Holmes... PHP Architect - A monthly magazine for PHP Professionals. Get your copy today. http://www.phparch.com/ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php