3

I have small issue with one of 3rd party system plugins that fires before my system plugin. We both use onAfterRoute but if that plugin is ordered before mine, my override is not taking place. I know that I can change the order of my plugin in backend and this way avoid the issue.

Thing I dont like is that I would need to do something like this in plugin install.script.php to make sure my plugin always fires first

$q->set(array('enabled = 1','ordering = -1000'));

http://prntscr.com/3totid

Yes , it is an ugly hack and another issue is that admin can still change the order.

So the question is , is it possible to do this from the system plugin itself? Something in JDispatcher maybe to order my plugin first?

Any help is appreciated!

1 Answer 1

3

The only way I could imagine is if you have an second system plugin which does that in an earlier event like onAfterInitialise. You would likely have to change it in the database directly then.

However imho, you should not do that at all. It's up to the system admin to decide in which order the plugins should fire. If your plugin needs to be first, tell the admin that she should check that.

1
  • we did exactly that and found out that the conflict plugin was doing something that it should not. it was rendering modules in onafterRoute. waiting for their fix.
    – Dan
    Jun 17, 2014 at 16:29

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.