Manual:Hooks/ParserAfterTidy
From MediaWiki.org
| ParserAfterTidy | |
|---|---|
| Available from version 1.5.0 Used to add some final processing to the fully-rendered page output |
|
*Define function: |
function fnMyHook(&$parser, &$text) { ... }
|
*Attach hook: |
$wgHooks['ParserAfterTidy'][] = 'fnMyHook'; |
| Called from: | Parser.php: Parser.parse() |
*For more information about attaching hooks, see Manual:Hooks.
*For examples of extensions using this hook, see Category:ParserAfterTidy extensions.
[edit] Details
$text will hold the text for the page. To change the page text, modify this value. E.g. to add the phrase "The mighty oracle gives forth this proclamation: " to the front of the page text, you would use the following code:
$text = "The mighty oracle gives forth this proclamation: " . $text;

