Manual:Hooks/ParserAfterParse

ParserAfterParse
Available from version 1.20.0
Called from Parser::parse() just after the call to Parser::internalParse() returns.
Define function:
public static function onParserAfterParse( Parser $parser, &$text, StripState $stripState ) { ... }
Attach hook: In extension.json:
{
	"Hooks": {
		"ParserAfterParse": "MediaWiki\\Extension\\MyExtension\\Hooks::onParserAfterParse"
	}
}
Called from: File(s): parser/Parser.php
Interface: ParserAfterParseHook.php

For more information about attaching hooks, see Manual:Hooks .
For examples of extensions using this hook, see Category:ParserAfterParse extensions.


Details

edit
  • $parser: parser object
  • &$text: text being parsed
  • $stripState: stripState used (object)