Need to change the output of two actions

Mr. Goodie2Shoes

Well-known member
To make it clear, there are two actions I need to modify that are on two different controller classes...
So how should I do it? Is there any way to use a listener instead of extending the classes?
And yes, I cannot use pre_dispatch as this needs to be done AFTER the action is executed.

Thanks!
 
You would extend those two controllers. Create a listener for load_class_controller to extend the class. Here is a code example of an extended controller:

http://xenforo.com/community/thread...-without-adding-a-template.38684/#post-427497

You can run the parent function, capture the response, do your own stuff, then return the original response (or modified response).
I know how that works... I am not new you know :P
just thinking if there's any other way to do it... since the output of both actions will be the same if a certain criteria meets I thought it would be better to reduce the size as much as possible...
 
Back
Top Bottom