Discussion in 'XenForo Development Discussions' started by silence, Aug 2, 2013.
How come I can only extend it within the actual class and not using the XF code listener?
This is basicly. You can extends
XenForo_ControllerAdmin_Abstract without listener_extends_class
Example: Your_Addon extends XenForo_ControllerAdmin_Abstract
No I got that, but how come for a ControllerPublic I can extend it using the XF listener, but with ControllerPublic I can't?
Your_Addon extends XenForo_ControllerPublic_Abstract
Why are you trying to inject a class for all ControllerAdmin classes? Use your listener with a very high priority (lower numbers >= larger numbers) and don't specify a class and just always add to $extend, you'll end up doing what you want.
Thanks, it's so simply I wouldn't have thought about doing that.
It's not guaranteed to be first but should work on most cases.
Separate names with a comma.