Manual:$wgParserOutputHooks

Details
This is an associative array where the key is an extension-defined tag (typically the extension name), and the value is a PHP callback.

These will be called as an  hook, if the relevant tag has been registered with the parser output object.

Registration is done with

The callback has the form: