I have two objects. Objects A and B.
A has a method that returns B. And I want to call it dynamically, so I use the line to call the method inside B as follows:
$method = 'getB()->someMethod';
But if you do this:
$a = new A(); $a->$method();
This does not work. Any ideas?
string object methods php
rix501
source share