Available from version 1.17.0
When parsing a XML tag in a log item.
Define function:
public static function onImportHandleLogItemXMLTag( $importer, $logInfo ) { ... }
Attach hook:

In extension.json:

	"Hooks": {
		"ImportHandleLogItemXMLTag": "MyExtensionHooks::onImportHandleLogItemXMLTag"

For MediaWiki ≤1.25:

$wgHooks['ImportHandleLogItemXMLTag'][] = 'MyExtensionHooks::onImportHandleLogItemXMLTag';
Called from:File(s): import/WikiImporter.php

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


  • $importer: WikiImporter object
  • $logInfo: Array of information

Return false to stop further processing of the tag