MediaWiki Hooks
www.mediawiki.org/wiki/Manual:Hooks
From the page
Saved with the link. Notes from 2007 to 2016 are mostly the page's own words, so this is probably an excerpt.
MediaWiki provides many hooks that can be used to extend the functionality of the MediaWiki software. Assigning a function (known as an event handler) to a hook will cause that function to be called at the appropriate point in the main MediaWiki code, to perform whatever additional task(s) the developer thinks would be useful at that point. Each hook can have multiple handlers assigned to it, in which case it will call the functions in the order that they are assigned, with any modifications made by one function passed on to subsequent functions in the chain.