dynamical class variable definition

From: Date: Mon, 13 Sep 2004 15:26:56 +0000
Subject: dynamical class variable definition
Groups: php.general 
Request: Send a blank email to php-general+get-196514@lists.php.net to get a copy of this message
Hi, I have a class, but the problem is that its variables need to be defined dynamically. example: class class_myclass{ var $variable1; var $variable2; var $variable3; ... var $variableN how to initialize these $variableN class variables from a global array which contains the variable names and custom count of them? if that's not possible.. maybe there's a possibility to initialize class variables on the fly from constructor class but the whole point is that the names and number of variables each php script run is different any suggestions? thanks a lot!

« previous php.general (#196514) next »