Manual:Hooks/DifferenceEngineLoadTextAfterNewContentIsLoaded

From MediaWiki.org
Jump to navigation Jump to search
DifferenceEngineLoadTextAfterNewContentIsLoaded
Available from version 1.29.0 (Gerrit change 322039)
called in DifferenceEngine::loadText() after the new revision's content has been loaded into the class member variable $differenceEngine->mNewContent but before checking if the variable's value is null.
Define function:
public static function onDifferenceEngineLoadTextAfterNewContentIsLoaded( $differenceEngine ) { ... }
Attach hook:

In extension.json:

{
	"Hooks": {
		"DifferenceEngineLoadTextAfterNewContentIsLoaded": "MyExtensionHooks::onDifferenceEngineLoadTextAfterNewContentIsLoaded"
	}
}

For MediaWiki ≤1.25:

$wgHooks['DifferenceEngineLoadTextAfterNewContentIsLoaded'][] = 'MyExtensionHooks::onDifferenceEngineLoadTextAfterNewContentIsLoaded';
Called from:File(s): DifferenceEngine.php
Function(s): loadText

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

Details[edit]

  • $differenceEngine: DifferenceEngine object