Add TitleExists hook
[lhc/web/wiklou.git] / docs / hooks.txt
index ad5377e..5be770e 100644 (file)
@@ -863,6 +863,14 @@ $name: name of the special page, e.g. 'Watchlist'
 &$join_conds: join conditions for the tables
 $opts: FormOptions for this request
 
+'LoginUserMigrated': Called during login to allow extensions the opportunity to
+inform a user that their username doesn't exist for a specific reason, instead
+of letting the login form give the generic error message that the account does
+not exist. For example, when the account has been renamed or deleted.
+$user: the User object being authenticated against.
+&$msg: the message identifier for abort reason, or an array to pass a message
+  key and parameters.
+
 'Collation::factory': Called if $wgCategoryCollation is an unknown collation.
 $collationName: Name of the collation in question
 &$collationObject: Null. Replace with a subclass of the Collation class that
@@ -1635,6 +1643,13 @@ $code: language code
 &$alldata: The localisation data from core and extensions
 &purgeBlobs: whether to purge/update the message blobs via MessageBlobStore::clear()
 
+'LocalisationCacheRecacheFallback': Called for each language when merging
+fallback data into the cache.
+$cache: The LocalisationCache object
+$code: language code
+&$alldata: The localisation data from core and extensions. Note some keys may
+  be omitted if they won't be merged into the final result.
+
 'LocalisationChecksBlacklist': When fetching the blacklist of
 localisation checks.
 &$blacklist: array of checks to blacklist. See the bottom of
@@ -2292,6 +2307,11 @@ $type: 'normal' or 'history' for old/diff views
 the MediaWiki icon but plain text instead.
 $skin: Skin object
 
+'SkinPreloadExistence': Supply titles that should be added to link existence
+cache before the page is rendered.
+&$titles: Array of Title objects
+$skin: Skin object
+
 'SkinSubPageSubtitle': At the beginning of Skin::subPageSubtitle().
 &$subpages: Subpage links HTML
 $skin: Skin object
@@ -2310,8 +2330,9 @@ $nav_urls: array of tabs
 which the actual html is constructed.
 &$languageLink: array containing data about the link. The following keys can be
   modified: href, text, title, class, lang, hreflang. Each of them is a string.
-$languageLinkTitle: Title object belonging to the external language link
-$title: Title object of the page the link belongs to
+$languageLinkTitle: Title object belonging to the external language link.
+$title: Title object of the page the link belongs to.
+$outputPage: The OutputPage object the links are built from.
 
 To alter the structured navigation links in SkinTemplates, there are three
 hooks called in different spots:
@@ -2569,6 +2590,10 @@ database result.
 &$titleArray: set this to an object to override the default object returned
 $res: database result used to create the object
 
+'TitleExists': Called when determining whether a page exists at a given title.
+$title: The title being tested.
+&$exists: Whether the title exists.
+
 'TitleQuickPermissions': Called from Title::checkQuickPermissions to add to
 or override the quick permissions check.
 $title: The Title object being accessed
@@ -2942,12 +2967,18 @@ $page: WikiPage object to be watched
 $user: user that watched
 $page: WikiPage object watched
 
+'WatchlistEditorBeforeFormRender': Before building the Special:EditWatchlist
+form, used to manipulate the list of pages or preload data based on that list.
+&$watchlistInfo: array of watchlisted pages in
+  [namespaceId => ['title1' => 1, 'title2' => 1]] format
+
 'WatchlistEditorBuildRemoveLine': when building remove lines in
 Special:Watchlist/edit.
 &$tools: array of extra links
 $title: Title object
 $redirect: whether the page is a redirect
 $skin: Skin object
+&$link: HTML link to title
 
 'WebRequestPathInfoRouter': While building the PathRouter to parse the
 REQUEST_URI.