So is it possible to do something like this with add_action?
class class{}
$my_class = new class;
add_action('init', 'my_class');
|
So is it possible to do something like this with
|
|||||
|
|
You can do this:
Or this:
It doesn't work like...
.. but I am not sure what you are trying to accomplish by using that pattern. You've already instantiated the class so the constructor, if present, has already ran. Without a callback method, I don't know what you expect to happen. |
|||