Index: trunk/phase3/docs/hooks.txt |
— | — | @@ -354,6 +354,11 @@ |
355 | 355 | $tokenFunctions array and return true (returning false makes no sense) |
356 | 356 | $tokenFunctions: array(action => callback) |
357 | 357 | |
| 358 | +'APIQuerySiteInfoGeneralInfo': use this hook to add extra information to |
| 359 | +the sites general information. |
| 360 | +$module: the current ApiQuerySiteInfo module |
| 361 | +$resutls: array of results, add things here |
| 362 | + |
358 | 363 | 'APIQueryUsersTokens': use this hook to add custom token to list=users. |
359 | 364 | Every token has an action, which will be used in the ustoken parameter |
360 | 365 | and in the output (actiontoken="..."), and a callback function which |
Index: trunk/phase3/includes/api/ApiQuerySiteinfo.php |
— | — | @@ -160,6 +160,8 @@ |
161 | 161 | $data['wikiid'] = wfWikiID(); |
162 | 162 | $data['time'] = wfTimestamp( TS_ISO_8601, time() ); |
163 | 163 | |
| 164 | + wfRunHooks( 'APIQuerySiteInfoGeneralInfo', array( &$this, &$data ) ); |
| 165 | + |
164 | 166 | return $this->getResult()->addValue( 'query', $property, $data ); |
165 | 167 | } |
166 | 168 | |
Index: trunk/phase3/RELEASE-NOTES |
— | — | @@ -271,6 +271,8 @@ |
272 | 272 | * (bug 27343) Add parseddescription to list=filearchive |
273 | 273 | * (bug 27469) label implicit groups in list=allusers&auprop=groups/ |
274 | 274 | list=users&usprop=groups |
| 275 | +* Addition of APIQuerySiteInfoGeneralInfo hook to add extra information to |
| 276 | + the general site info results |
275 | 277 | |
276 | 278 | === Languages updated in 1.18 === |
277 | 279 | |