X-Git-Url: https://git.cyclocoop.org/?a=blobdiff_plain;f=docs%2Fhooks.txt;h=96a72df677472c398d219bff92602f0c0e624383;hb=cba23cc37e55caded76d2a4c6b6125db4f92e63e;hp=2d1001ba52df78bb8ec522caf208e3004ab32660;hpb=5c3fecdb372bbd96301a1c21d8fae3219c55a356;p=lhc%2Fweb%2Fwiklou.git diff --git a/docs/hooks.txt b/docs/hooks.txt index 2d1001ba52..96a72df677 100644 --- a/docs/hooks.txt +++ b/docs/hooks.txt @@ -432,6 +432,10 @@ sites general information. $module: the current ApiQuerySiteInfo module &$results: array of results, add things here +'APIQuerySiteInfoStatisticsInfo': Use this hook to add extra information to the +sites statistics information. +&$results: array of results, add things here + 'APIQueryUsersTokens': Use this hook to add custom token to list=users. Every token has an action, which will be used in the ustoken parameter and in the output (actiontoken="..."), and a callback function which should return the @@ -862,10 +866,6 @@ etc. 'DatabaseOraclePostInit': Called after initialising an Oracle database &$db: the DatabaseOracle object -'Debug': Called when outputting a debug log line via wfDebug() or wfDebugLog() -$text: plaintext string to be output -$group: null or a string naming a logging group (as defined in $wgDebugLogGroups) - 'NewDifferenceEngine': Called when a new DifferenceEngine object is made $title: the diff page title (nullable) &$oldId: the actual old Id to use in the diff @@ -1157,6 +1157,16 @@ $title: Title object that we need to get a sortkey for underscore) magic words. Called by MagicWord. &$doubleUnderscoreIDs: array of strings +'GetExtendedMetadata': Get extended file metadata for the API +&$combinedMeta: Array of the form: 'MetadataPropName' => array( +'value' => prop value, 'source' => 'name of hook' ). +$file: File object of file in question +$context: RequestContext (including language to use) +$single: Only extract the current language; if false, the prop value should +be in the metadata multi-language array format: +mediawiki.org/wiki/Manual:File_metadata_handling#Multi-language_array_format +&$maxCacheTime: how long the results can be cached + 'GetFullURL': Modify fully-qualified URLs used in redirects/export/offsite data. $title: Title object of page $url: string value as output (out parameter, can modify) @@ -1598,7 +1608,7 @@ $wcOnlySysopsCanPatrol: config setting indicating whether the user must be a something completely different, after the basic globals have been set up, but before ordinary actions take place. $output: $wgOut -$article: $wgArticle +$article: Article on which the action will be performed $title: $wgTitle $user: $wgUser $request: $wgRequest @@ -2365,6 +2375,11 @@ $special: the special page object &$fields: array of query fields $values: array of variables with watchlist options +'SpecialWatchlistGetNonRevisionTypes': Called when building sql query for +SpecialWatchlist. Allows extensions to register custom values they have +inserted to rc_type so they can be returned as part of the watchlist. +&$nonRevisionTypes: array of values in the rc_type field of recentchanges table + 'TestCanonicalRedirect': Called when about to force a redirect to a canonical URL for a title when we have no other parameters on the URL. Gives a chance for extensions that alter page view behavior radically to abort that redirect or @@ -2574,6 +2589,7 @@ $user: User (object) whose permission is being checked 'UserClearNewTalkNotification': Called when clearing the "You have new messages!" message, return false to not delete it. $user: User (object) that will clear the message +$oldid: ID of the talk page revision being viewed (0 means the most recent one) 'UserComparePasswords': Called when checking passwords, return false to override the default password checks. @@ -2738,6 +2754,12 @@ $userId: User id of the current user $userText: User name of the current user &$items: Array of user tool links as HTML fragments +'ValidateExtendedMetadataCache': Called to validate the cached metadata in +FormatMetadata::getExtendedMeta (return false means cache will be +invalidated and GetExtendedMetadata hook called again). +$timestamp: The timestamp metadata was generated +$file: The file the metadata is for + 'WantedPages::getQueryInfo': Called in WantedPagesPage::getQueryInfo(), can be used to alter the SQL query which gets the list of wanted pages. &$wantedPages: WantedPagesPage object