Manual:Hooks/AfterImportPage

AfterImportPage
Available from version 1.17.0
When a page import is completed
Define function:
public static function onAfterImportPage( $title, $origTitle, $revCount, $sRevCount, $pageInfo ) { ... }
Attach hook: In extension.json:
{
	"Hooks": {
		"AfterImportPage": "MyExtensionHooks::onAfterImportPage"
	}
}
Called from: File(s): import/WikiImporter.php
Interface: AfterImportPageHook.php

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


DetailsEdit

  • $title: Title under which the revisions were imported
  • $origTitle: Title provided by the XML file
  • $revCount: Number of revisions in the XML file
  • $sRevCount: Number of sucessfully imported revisions
  • $pageInfo: associative array of page information