Creating a dynamic class instance programmatically in PHP with variable arguments?

Viewed 9376

I've some code that creates ad instance with a dynamic class (i.e. from a variable):

$instance = new $myClass();

Since the constructor has different argument count depending on $myClass value, How do I pass a variable list of arguments to the new statement? Is it possible?

3 Answers
Related