Jack Bates-2 wrote:
> How do I access a static variable when I do not know the name of the
> class until runtime?
Why not just:

eval('$staticVal = '.get_class($myClass).'::staticVarName;');

...now the value is in $staticVal.

Or am I missing something here?  No need to tell me eval is evil  ;)
View this message in context: 
Sent from the PHP - General mailing list archive at Nabble.com.

PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to