
0
Completed
Custom event catchall handler
Hello,
I was reading about custom event script (https://docs.filerun.com/custom_event_scripts) and it wold be great to have one extra option :
> generic catchall events file handler to be able to centralize and route all events from one single file since all events already have the $action variable with the event name.
Customer support service by UserEcho
We could add that. May I ask about the purpose of it?
I'm developing a integration with a CMS where multiple events should trigger specific handlers to update the CMS.
At this point I have some specific key tasks I want to perform but i'm not sure of all the events I should use and what other events could be useful and I dint even think they could.
For this purpose of exploring, testing, logging and centralize to prevent code repetition because some events will trigger the same handler, I think one catchall events file wold be great.
Thanks! and great work btw =)
With the next FileRun update, the config option $config['app']['enable_catch_all_event'] can be set to true to have FileRun look for the file "customizables/events/catch-all.php" and if it exists, it will run it every time a user performs an action.