Index: trunk/phase3/includes/api/ApiQuerySearch.php |
— | — | @@ -209,14 +209,14 @@ |
210 | 210 | |
211 | 211 | public function getParamDescription() { |
212 | 212 | return array( |
213 | | - 'search' => 'Search for all page titles (or content) that has this value.', |
214 | | - 'namespace' => 'The namespace(s) to enumerate.', |
215 | | - 'what' => 'Search inside the text or titles.', |
216 | | - 'info' => 'What metadata to return.', |
217 | | - 'prop' => 'What properties to return.', |
218 | | - 'redirects' => 'Include redirect pages in the search.', |
| 213 | + 'search' => 'Search for all page titles (or content) that has this value', |
| 214 | + 'namespace' => 'The namespace(s) to enumerate', |
| 215 | + 'what' => 'Search inside the text or titles', |
| 216 | + 'info' => 'What metadata to return', |
| 217 | + 'prop' => 'What properties to return', |
| 218 | + 'redirects' => 'Include redirect pages in the search', |
219 | 219 | 'offset' => 'Use this value to continue paging (return by query)', |
220 | | - 'limit' => 'How many total pages to return.' |
| 220 | + 'limit' => 'How many total pages to return' |
221 | 221 | ); |
222 | 222 | } |
223 | 223 | |
Index: trunk/phase3/includes/api/ApiQueryLogEvents.php |
— | — | @@ -356,18 +356,18 @@ |
357 | 357 | 'prop' => 'Which properties to get', |
358 | 358 | 'type' => 'Filter log entries to only this type(s)', |
359 | 359 | 'action' => "Filter log actions to only this type. Overrides {$this->getModulePrefix()}type", |
360 | | - 'start' => 'The timestamp to start enumerating from.', |
361 | | - 'end' => 'The timestamp to end enumerating.', |
362 | | - 'dir' => 'In which direction to enumerate.', |
363 | | - 'user' => 'Filter entries to those made by the given user.', |
364 | | - 'title' => 'Filter entries to those related to a page.', |
365 | | - 'limit' => 'How many total event entries to return.', |
366 | | - 'tag' => 'Only list event entries tagged with this tag.', |
| 360 | + 'start' => 'The timestamp to start enumerating from', |
| 361 | + 'end' => 'The timestamp to end enumerating', |
| 362 | + 'dir' => 'In which direction to enumerate', |
| 363 | + 'user' => 'Filter entries to those made by the given user', |
| 364 | + 'title' => 'Filter entries to those related to a page', |
| 365 | + 'limit' => 'How many total event entries to return', |
| 366 | + 'tag' => 'Only list event entries tagged with this tag', |
367 | 367 | ); |
368 | 368 | } |
369 | 369 | |
370 | 370 | public function getDescription() { |
371 | | - return 'Get events from logs.'; |
| 371 | + return 'Get events from logs'; |
372 | 372 | } |
373 | 373 | |
374 | 374 | public function getPossibleErrors() { |
Index: trunk/phase3/includes/api/ApiUnblock.php |
— | — | @@ -103,10 +103,11 @@ |
104 | 104 | } |
105 | 105 | |
106 | 106 | public function getParamDescription() { |
| 107 | + $p = $this->getModulePrefix(); |
107 | 108 | return array( |
108 | | - 'id' => 'ID of the block you want to unblock (obtained through list=blocks). Cannot be used together with user', |
109 | | - 'user' => 'Username, IP address or IP range you want to unblock. Cannot be used together with id', |
110 | | - 'token' => 'An unblock token previously obtained through the gettoken parameter or prop=info', |
| 109 | + 'id' => "ID of the block you want to unblock (obtained through list=blocks). Cannot be used together with {$p}user", |
| 110 | + 'user' => "Username, IP address or IP range you want to unblock. Cannot be used together with {$p}id", |
| 111 | + 'token' => "An unblock token previously obtained through the gettoken parameter or {$p}prop=info", |
111 | 112 | 'gettoken' => 'If set, an unblock token will be returned, and no other action will be taken', |
112 | 113 | 'reason' => 'Reason for unblock (optional)', |
113 | 114 | ); |
— | — | @@ -114,7 +115,7 @@ |
115 | 116 | |
116 | 117 | public function getDescription() { |
117 | 118 | return array( |
118 | | - 'Unblock a user.' |
| 119 | + 'Unblock a user' |
119 | 120 | ); |
120 | 121 | } |
121 | 122 | |
Index: trunk/phase3/includes/api/ApiQueryWatchlistRaw.php |
— | — | @@ -164,10 +164,10 @@ |
165 | 165 | public function getParamDescription() { |
166 | 166 | return array( |
167 | 167 | 'continue' => 'When more results are available, use this to continue', |
168 | | - 'namespace' => 'Only list pages in the given namespace(s).', |
169 | | - 'limit' => 'How many total results to return per request.', |
170 | | - 'prop' => 'Which additional properties to get (non-generator mode only).', |
171 | | - 'show' => 'Only list items that meet these criteria.', |
| 168 | + 'namespace' => 'Only list pages in the given namespace(s)', |
| 169 | + 'limit' => 'How many total results to return per request', |
| 170 | + 'prop' => 'Which additional properties to get (non-generator mode only)', |
| 171 | + 'show' => 'Only list items that meet these criteria', |
172 | 172 | ); |
173 | 173 | } |
174 | 174 | |
Index: trunk/phase3/includes/api/ApiQueryProtectedTitles.php |
— | — | @@ -183,7 +183,7 @@ |
184 | 184 | 'start' => 'Start listing at this protection timestamp', |
185 | 185 | 'end' => 'Stop listing at this protection timestamp', |
186 | 186 | 'dir' => 'The direction in which to list', |
187 | | - 'limit' => 'How many total pages to return.', |
| 187 | + 'limit' => 'How many total pages to return', |
188 | 188 | 'prop' => 'Which properties to get', |
189 | 189 | 'level' => 'Only list titles with these protection levels', |
190 | 190 | ); |
Index: trunk/phase3/includes/api/ApiFormatDbg.php |
— | — | @@ -29,6 +29,7 @@ |
30 | 30 | } |
31 | 31 | |
32 | 32 | /** |
| 33 | + * API PHP's var_export() output formatter |
33 | 34 | * @ingroup API |
34 | 35 | */ |
35 | 36 | class ApiFormatDbg extends ApiFormatBase { |
Index: trunk/phase3/includes/api/ApiQuery.php |
— | — | @@ -573,7 +573,7 @@ |
574 | 574 | 'generator' => array( 'Use the output of a list as the input for other prop/list/meta items', |
575 | 575 | 'NOTE: generator parameter names must be prefixed with a \'g\', see examples.' ), |
576 | 576 | 'redirects' => 'Automatically resolve redirects', |
577 | | - 'indexpageids' => 'Include an additional pageids section listing all returned page IDs.', |
| 577 | + 'indexpageids' => 'Include an additional pageids section listing all returned page IDs', |
578 | 578 | 'export' => 'Export the current revisions of all given or generated pages', |
579 | 579 | 'exportnowrap' => 'Return the export XML without wrapping it in an XML result (same format as Special:Export). Can only be used with export', |
580 | 580 | ); |
— | — | @@ -583,7 +583,7 @@ |
584 | 584 | return array( |
585 | 585 | 'Query API module allows applications to get needed pieces of data from the MediaWiki databases,', |
586 | 586 | 'and is loosely based on the old query.php interface.', |
587 | | - 'All data modifications will first have to use query to acquire a token to prevent abuse from malicious sites.' |
| 587 | + 'All data modifications will first have to use query to acquire a token to prevent abuse from malicious sites' |
588 | 588 | ); |
589 | 589 | } |
590 | 590 | |
Index: trunk/phase3/includes/api/ApiLogin.php |
— | — | @@ -179,7 +179,7 @@ |
180 | 180 | 'In the event of a successful log-in, a cookie will be attached', |
181 | 181 | 'to your session. In the event of a failed log-in, you will not ', |
182 | 182 | 'be able to attempt another log-in through this method for 5 seconds.', |
183 | | - 'This is to prevent password guessing by automated password crackers.' |
| 183 | + 'This is to prevent password guessing by automated password crackers' |
184 | 184 | ); |
185 | 185 | } |
186 | 186 | |
Index: trunk/phase3/includes/api/ApiFormatXml.php |
— | — | @@ -29,6 +29,7 @@ |
30 | 30 | } |
31 | 31 | |
32 | 32 | /** |
| 33 | + * API XML output formatter |
33 | 34 | * @ingroup API |
34 | 35 | */ |
35 | 36 | class ApiFormatXml extends ApiFormatBase { |
— | — | @@ -196,7 +197,7 @@ |
197 | 198 | |
198 | 199 | public function getParamDescription() { |
199 | 200 | return array( |
200 | | - 'xmldoublequote' => 'If specified, double quotes all attributes and content.', |
| 201 | + 'xmldoublequote' => 'If specified, double quotes all attributes and content', |
201 | 202 | 'xslt' => 'If specified, adds <xslt> as stylesheet', |
202 | 203 | ); |
203 | 204 | } |
Index: trunk/phase3/includes/api/ApiFormatJson.php |
— | — | @@ -29,6 +29,7 @@ |
30 | 30 | } |
31 | 31 | |
32 | 32 | /** |
| 33 | + * API JSON output formatter |
33 | 34 | * @ingroup API |
34 | 35 | */ |
35 | 36 | class ApiFormatJson extends ApiFormatBase { |
Index: trunk/phase3/includes/api/ApiMain.php |
— | — | @@ -634,7 +634,7 @@ |
635 | 635 | '', |
636 | 636 | 'Status: All features shown on this page should be working, but the API', |
637 | 637 | ' is still in active development, and may change at any time.', |
638 | | - ' Make sure to monitor our mailing list for any updates.', |
| 638 | + ' Make sure to monitor our mailing list for any updates', |
639 | 639 | '', |
640 | 640 | 'Documentation: http://www.mediawiki.org/wiki/API', |
641 | 641 | 'Mailing list: http://lists.wikimedia.org/mailman/listinfo/mediawiki-api', |
Index: trunk/phase3/includes/api/ApiQueryImageInfo.php |
— | — | @@ -318,14 +318,15 @@ |
319 | 319 | } |
320 | 320 | |
321 | 321 | public function getParamDescription() { |
| 322 | + $p = $this->getModulePrefix(); |
322 | 323 | return array( |
323 | | - 'prop' => 'What image information to get.', |
| 324 | + 'prop' => 'What image information to get', |
324 | 325 | 'limit' => 'How many image revisions to return', |
325 | 326 | 'start' => 'Timestamp to start listing from', |
326 | 327 | 'end' => 'Timestamp to stop listing at', |
327 | | - 'urlwidth' => array( 'If iiprop=url is set, a URL to an image scaled to this width will be returned.', |
328 | | - 'Only the current version of the image can be scaled.' ), |
329 | | - 'urlheight' => 'Similar to iiurlwidth. Cannot be used without iiurlwidth', |
| 328 | + 'urlwidth' => array( "If {$p}prop=url is set, a URL to an image scaled to this width will be returned.", |
| 329 | + 'Only the current version of the image can be scaled' ), |
| 330 | + 'urlheight' => "Similar to {$p}urlwidth. Cannot be used without {$p}urlwidth", |
330 | 331 | 'continue' => 'When more results are available, use this to continue', |
331 | 332 | ); |
332 | 333 | } |
Index: trunk/phase3/includes/api/ApiEmailUser.php |
— | — | @@ -28,6 +28,7 @@ |
29 | 29 | } |
30 | 30 | |
31 | 31 | /** |
| 32 | + * API Module to facilitate sending of emails to users |
32 | 33 | * @ingroup API |
33 | 34 | */ |
34 | 35 | class ApiEmailUser extends ApiBase { |
Index: trunk/phase3/includes/api/ApiQueryWatchlist.php |
— | — | @@ -363,21 +363,21 @@ |
364 | 364 | |
365 | 365 | public function getParamDescription() { |
366 | 366 | return array( |
367 | | - 'allrev' => 'Include multiple revisions of the same page within given timeframe.', |
368 | | - 'start' => 'The timestamp to start enumerating from.', |
369 | | - 'end' => 'The timestamp to end enumerating.', |
370 | | - 'namespace' => 'Filter changes to only the given namespace(s).', |
| 367 | + 'allrev' => 'Include multiple revisions of the same page within given timeframe', |
| 368 | + 'start' => 'The timestamp to start enumerating from', |
| 369 | + 'end' => 'The timestamp to end enumerating', |
| 370 | + 'namespace' => 'Filter changes to only the given namespace(s)', |
371 | 371 | 'user' => 'Only list changes by this user', |
372 | 372 | 'excludeuser' => 'Don\'t list changes by this user', |
373 | | - 'dir' => 'In which direction to enumerate pages.', |
374 | | - 'limit' => 'How many total results to return per request.', |
| 373 | + 'dir' => 'In which direction to enumerate pages', |
| 374 | + 'limit' => 'How many total results to return per request', |
375 | 375 | 'prop' => 'Which additional items to get (non-generator mode only).', |
376 | 376 | 'show' => array( |
377 | 377 | 'Show only items that meet this criteria.', |
378 | | - 'For example, to see only minor edits done by logged-in users, set show=minor|!anon' |
| 378 | + "For example, to see only minor edits done by logged-in users, set {$this->getModulePrefix()}show=minor|!anon" |
379 | 379 | ), |
380 | | - 'owner' => "The name of the user whose watchlist you'd like to access", |
381 | | - 'token' => "Give a security token (settable in preferences) to allow access to another user's watchlist" |
| 380 | + 'owner' => 'The name of the user whose watchlist you\'d like to access', |
| 381 | + 'token' => 'Give a security token (settable in preferences) to allow access to another user\'s watchlist' |
382 | 382 | ); |
383 | 383 | } |
384 | 384 | |
Index: trunk/phase3/includes/api/ApiBlock.php |
— | — | @@ -169,7 +169,7 @@ |
170 | 170 | |
171 | 171 | public function getDescription() { |
172 | 172 | return array( |
173 | | - 'Block a user.' |
| 173 | + 'Block a user' |
174 | 174 | ); |
175 | 175 | } |
176 | 176 | |
Index: trunk/phase3/includes/api/ApiPatrol.php |
— | — | @@ -84,7 +84,7 @@ |
85 | 85 | |
86 | 86 | public function getDescription() { |
87 | 87 | return array( |
88 | | - 'Patrol a page or revision. ' |
| 88 | + 'Patrol a page or revision' |
89 | 89 | ); |
90 | 90 | } |
91 | 91 | |
Index: trunk/phase3/includes/api/ApiUndelete.php |
— | — | @@ -121,7 +121,7 @@ |
122 | 122 | |
123 | 123 | public function getParamDescription() { |
124 | 124 | return array( |
125 | | - 'title' => 'Title of the page you want to restore.', |
| 125 | + 'title' => 'Title of the page you want to restore', |
126 | 126 | 'token' => 'An undelete token previously retrieved through list=deletedrevs', |
127 | 127 | 'reason' => 'Reason for restoring (optional)', |
128 | 128 | 'timestamps' => 'Timestamps of the revisions to restore. If not set, all revisions will be restored.', |
Index: trunk/phase3/includes/api/ApiQueryRevisions.php |
— | — | @@ -546,8 +546,9 @@ |
547 | 547 | } |
548 | 548 | |
549 | 549 | public function getParamDescription() { |
| 550 | + $p = $this->getModulePrefix(); |
550 | 551 | return array( |
551 | | - 'prop' => 'Which properties to get for each revision.', |
| 552 | + 'prop' => 'Which properties to get for each revision', |
552 | 553 | 'limit' => 'Limit how many revisions will be returned (enum)', |
553 | 554 | 'startid' => 'From which revision id to start enumeration (enum)', |
554 | 555 | 'endid' => 'Stop revision enumeration on this revid (enum)', |
— | — | @@ -562,21 +563,21 @@ |
563 | 564 | 'token' => 'Which tokens to obtain for each revision', |
564 | 565 | 'continue' => 'When more results are available, use this to continue', |
565 | 566 | 'diffto' => array( 'Revision ID to diff each revision to.', |
566 | | - 'Use "prev", "next" and "cur" for the previous, next and current revision respectively.' ), |
| 567 | + 'Use "prev", "next" and "cur" for the previous, next and current revision respectively' ), |
567 | 568 | 'difftotext' => array( 'Text to diff each revision to. Only diffs a limited number of revisions.', |
568 | | - 'Overrides diffto. If rvsection is set, only that section will be diffed against this text.' ), |
| 569 | + "Overrides {$p}diffto. If {$p}section is set, only that section will be diffed against this text" ), |
569 | 570 | 'tag' => 'Only list revisions tagged with this tag', |
570 | 571 | ); |
571 | 572 | } |
572 | 573 | |
573 | 574 | public function getDescription() { |
574 | 575 | return array( |
575 | | - 'Get revision information.', |
| 576 | + 'Get revision information', |
576 | 577 | 'This module may be used in several ways:', |
577 | | - ' 1) Get data about a set of pages (last revision), by setting titles or pageids parameter.', |
578 | | - ' 2) Get revisions for one given page, by using titles/pageids with start/end/limit params.', |
579 | | - ' 3) Get data about a set of revisions by setting their IDs with revids parameter.', |
580 | | - 'All parameters marked as (enum) may only be used with a single page (#2).' |
| 578 | + ' 1) Get data about a set of pages (last revision), by setting titles or pageids parameter', |
| 579 | + ' 2) Get revisions for one given page, by using titles/pageids with start/end/limit params', |
| 580 | + ' 3) Get data about a set of revisions by setting their IDs with revids parameter', |
| 581 | + 'All parameters marked as (enum) may only be used with a single page (#2)' |
581 | 582 | ); |
582 | 583 | } |
583 | 584 | |
Index: trunk/phase3/includes/api/ApiQueryCategories.php |
— | — | @@ -211,7 +211,7 @@ |
212 | 212 | |
213 | 213 | public function getParamDescription() { |
214 | 214 | return array( |
215 | | - 'prop' => 'Which additional properties to get for each category.', |
| 215 | + 'prop' => 'Which additional properties to get for each category', |
216 | 216 | 'limit' => 'How many categories to return', |
217 | 217 | 'show' => 'Which kind of categories to show', |
218 | 218 | 'continue' => 'When more results are available, use this to continue', |
Index: trunk/phase3/includes/api/ApiQueryAllUsers.php |
— | — | @@ -221,13 +221,13 @@ |
222 | 222 | |
223 | 223 | public function getParamDescription() { |
224 | 224 | return array( |
225 | | - 'from' => 'The user name to start enumerating from.', |
226 | | - 'prefix' => 'Search for all page titles that begin with this value.', |
| 225 | + 'from' => 'The user name to start enumerating from', |
| 226 | + 'prefix' => 'Search for all page titles that begin with this value', |
227 | 227 | 'group' => 'Limit users to a given group name', |
228 | 228 | 'prop' => array( |
229 | 229 | 'What pieces of information to include.', |
230 | | - '`groups` property uses more server resources and may return fewer results than the limit.' ), |
231 | | - 'limit' => 'How many total user names to return.', |
| 230 | + '`groups` property uses more server resources and may return fewer results than the limit' ), |
| 231 | + 'limit' => 'How many total user names to return', |
232 | 232 | 'witheditsonly' => 'Only list users who have made edits', |
233 | 233 | ); |
234 | 234 | } |
Index: trunk/phase3/includes/api/ApiQueryDuplicateFiles.php |
— | — | @@ -145,7 +145,7 @@ |
146 | 146 | } |
147 | 147 | |
148 | 148 | public function getDescription() { |
149 | | - return 'List all files that are duplicates of the given file(s).'; |
| 149 | + return 'List all files that are duplicates of the given file(s)'; |
150 | 150 | } |
151 | 151 | |
152 | 152 | public function getPossibleErrors() { |
Index: trunk/phase3/includes/api/ApiUpload.php |
— | — | @@ -338,7 +338,7 @@ |
339 | 339 | 'Note that the HTTP POST must be done as a file upload (i.e. using multipart/form-data) when', |
340 | 340 | 'sending the "file". Note also that queries using session keys must be', |
341 | 341 | 'done in the same login session as the query that originally returned the key (i.e. do not', |
342 | | - 'log out and then log back in). Also you must get and send an edit token before doing any upload stuff.' |
| 342 | + 'log out and then log back in). Also you must get and send an edit token before doing any upload stuff' |
343 | 343 | ); |
344 | 344 | } |
345 | 345 | |
Index: trunk/phase3/includes/api/ApiQueryTags.php |
— | — | @@ -166,7 +166,7 @@ |
167 | 167 | } |
168 | 168 | |
169 | 169 | public function getDescription() { |
170 | | - return 'List change tags.'; |
| 170 | + return 'List change tags'; |
171 | 171 | } |
172 | 172 | |
173 | 173 | protected function getExamples() { |
Index: trunk/phase3/includes/api/ApiFeedWatchlist.php |
— | — | @@ -173,8 +173,8 @@ |
174 | 174 | return array( |
175 | 175 | 'feedformat' => 'The format of the feed', |
176 | 176 | 'hours' => 'List pages modified within this many hours from now', |
177 | | - 'allrev' => 'Include multiple revisions of the same page within given timeframe.', |
178 | | - 'wlowner' => "The user whose watchlist you want (must be accompanied by wltoken if it's not you)", |
| 177 | + 'allrev' => 'Include multiple revisions of the same page within given timeframe', |
| 178 | + 'wlowner' => "The user whose watchlist you want (must be accompanied by {$this->getModulePrefix()}token if it's not you)", |
179 | 179 | 'wltoken' => 'Security token that requested user set in their preferences' |
180 | 180 | ); |
181 | 181 | } |
Index: trunk/phase3/includes/api/ApiQueryUserContributions.php |
— | — | @@ -410,18 +410,19 @@ |
411 | 411 | } |
412 | 412 | |
413 | 413 | public function getParamDescription() { |
| 414 | + $p = $this->getModulePrefix(); |
414 | 415 | return array( |
415 | | - 'limit' => 'The maximum number of contributions to return.', |
416 | | - 'start' => 'The start timestamp to return from.', |
417 | | - 'end' => 'The end timestamp to return to.', |
418 | | - 'continue' => 'When more results are available, use this to continue.', |
419 | | - 'user' => 'The user to retrieve contributions for.', |
420 | | - 'userprefix' => 'Retrieve contibutions for all users whose names begin with this value. Overrides ucuser.', |
421 | | - 'dir' => 'The direction to search (older or newer).', |
| 416 | + 'limit' => 'The maximum number of contributions to return', |
| 417 | + 'start' => 'The start timestamp to return from', |
| 418 | + 'end' => 'The end timestamp to return to', |
| 419 | + 'continue' => 'When more results are available, use this to continue', |
| 420 | + 'user' => 'The user to retrieve contributions for', |
| 421 | + 'userprefix' => "Retrieve contibutions for all users whose names begin with this value. Overrides {$p}user", |
| 422 | + 'dir' => 'The direction to search (older or newer)', |
422 | 423 | 'namespace' => 'Only list contributions in these namespaces', |
423 | 424 | 'prop' => 'Include additional pieces of information', |
424 | | - 'show' => array( 'Show only items that meet this criteria, e.g. non minor edits only: show=!minor', |
425 | | - 'NOTE: if show=patrolled or show=!patrolled is set, revisions older than $wgRCMaxAge won\'t be shown', ), |
| 425 | + 'show' => array( "Show only items that meet this criteria, e.g. non minor edits only: {$p}show=!minor", |
| 426 | + "NOTE: if show=patrolled or {$p}show=!patrolled is set, revisions older than $wgRCMaxAge won\'t be shown", ), |
426 | 427 | 'tag' => 'Only list revisions tagged with this tag', |
427 | 428 | ); |
428 | 429 | } |
Index: trunk/phase3/includes/api/ApiQueryAllLinks.php |
— | — | @@ -184,13 +184,13 @@ |
185 | 185 | |
186 | 186 | public function getParamDescription() { |
187 | 187 | return array( |
188 | | - 'from' => 'The page title to start enumerating from.', |
189 | | - 'prefix' => 'Search for all page titles that begin with this value.', |
190 | | - 'unique' => 'Only show unique links. Cannot be used with generator or prop=ids', |
| 188 | + 'from' => 'The page title to start enumerating from', |
| 189 | + 'prefix' => 'Search for all page titles that begin with this value', |
| 190 | + 'unique' => "Only show unique links. Cannot be used with generator or {$this->getModulePrefix()}prop=ids", |
191 | 191 | 'prop' => 'What pieces of information to include', |
192 | | - 'namespace' => 'The namespace to enumerate.', |
193 | | - 'limit' => 'How many total links to return.', |
194 | | - 'continue' => 'When more results are available, use this to continue.', |
| 192 | + 'namespace' => 'The namespace to enumerate', |
| 193 | + 'limit' => 'How many total links to return', |
| 194 | + 'continue' => 'When more results are available, use this to continue', |
195 | 195 | ); |
196 | 196 | } |
197 | 197 | |
Index: trunk/phase3/includes/api/ApiQueryRecentChanges.php |
— | — | @@ -530,9 +530,9 @@ |
531 | 531 | |
532 | 532 | public function getParamDescription() { |
533 | 533 | return array( |
534 | | - 'start' => 'The timestamp to start enumerating from.', |
535 | | - 'end' => 'The timestamp to end enumerating.', |
536 | | - 'dir' => 'In which direction to enumerate.', |
| 534 | + 'start' => 'The timestamp to start enumerating from', |
| 535 | + 'end' => 'The timestamp to end enumerating', |
| 536 | + 'dir' => 'In which direction to enumerate', |
537 | 537 | 'namespace' => 'Filter log entries to only this namespace(s)', |
538 | 538 | 'user' => 'Only list changes by this user', |
539 | 539 | 'excludeuser' => 'Don\'t list changes by this user', |
— | — | @@ -540,11 +540,11 @@ |
541 | 541 | 'token' => 'Which tokens to obtain for each change', |
542 | 542 | 'show' => array( |
543 | 543 | 'Show only items that meet this criteria.', |
544 | | - 'For example, to see only minor edits done by logged-in users, set show=minor|!anon' |
| 544 | + "For example, to see only minor edits done by logged-in users, set {$this->getModulePrefix()}show=minor|!anon" |
545 | 545 | ), |
546 | | - 'type' => 'Which types of changes to show.', |
547 | | - 'limit' => 'How many total changes to return.', |
548 | | - 'tag' => 'Only list changes tagged with this tag.', |
| 546 | + 'type' => 'Which types of changes to show', |
| 547 | + 'limit' => 'How many total changes to return', |
| 548 | + 'tag' => 'Only list changes tagged with this tag', |
549 | 549 | ); |
550 | 550 | } |
551 | 551 | |
Index: trunk/phase3/includes/api/ApiQueryAllCategories.php |
— | — | @@ -154,10 +154,10 @@ |
155 | 155 | |
156 | 156 | public function getParamDescription() { |
157 | 157 | return array( |
158 | | - 'from' => 'The category to start enumerating from.', |
159 | | - 'prefix' => 'Search for all category titles that begin with this value.', |
160 | | - 'dir' => 'Direction to sort in.', |
161 | | - 'limit' => 'How many categories to return.', |
| 158 | + 'from' => 'The category to start enumerating from', |
| 159 | + 'prefix' => 'Search for all category titles that begin with this value', |
| 160 | + 'dir' => 'Direction to sort in', |
| 161 | + 'limit' => 'How many categories to return', |
162 | 162 | 'prop' => 'Which properties to get', |
163 | 163 | ); |
164 | 164 | } |
Index: trunk/phase3/includes/api/ApiMove.php |
— | — | @@ -28,6 +28,7 @@ |
29 | 29 | } |
30 | 30 | |
31 | 31 | /** |
| 32 | + * API Module to move pages |
32 | 33 | * @ingroup API |
33 | 34 | */ |
34 | 35 | class ApiMove extends ApiBase { |
— | — | @@ -202,13 +203,14 @@ |
203 | 204 | } |
204 | 205 | |
205 | 206 | public function getParamDescription() { |
| 207 | + $p = $this->getModulePrefix(); |
206 | 208 | return array( |
207 | | - 'from' => 'Title of the page you want to move. Cannot be used together with fromid.', |
208 | | - 'fromid' => 'Page ID of the page you want to move. Cannot be used together with from.', |
209 | | - 'to' => 'Title you want to rename the page to.', |
| 209 | + 'from' => "Title of the page you want to move. Cannot be used together with {$p}fromid", |
| 210 | + 'fromid' => "Page ID of the page you want to move. Cannot be used together with {$p}from", |
| 211 | + 'to' => 'Title you want to rename the page to', |
210 | 212 | 'token' => 'A move token previously retrieved through prop=info', |
211 | | - 'reason' => 'Reason for the move (optional).', |
212 | | - 'movetalk' => 'Move the talk page, if it exists.', |
| 213 | + 'reason' => 'Reason for the move (optional)', |
| 214 | + 'movetalk' => 'Move the talk page, if it exists', |
213 | 215 | 'movesubpages' => 'Move subpages, if applicable', |
214 | 216 | 'noredirect' => 'Don\'t create a redirect', |
215 | 217 | 'watch' => 'Add the page and the redirect to your watchlist', |
— | — | @@ -220,7 +222,7 @@ |
221 | 223 | |
222 | 224 | public function getDescription() { |
223 | 225 | return array( |
224 | | - 'Move a page.' |
| 226 | + 'Move a page' |
225 | 227 | ); |
226 | 228 | } |
227 | 229 | |
Index: trunk/phase3/includes/api/ApiQueryLinks.php |
— | — | @@ -182,9 +182,10 @@ |
183 | 183 | } |
184 | 184 | |
185 | 185 | public function getParamDescription() { |
| 186 | + $desc = $this->description; |
186 | 187 | return array( |
187 | | - 'namespace' => "Show {$this->description}s in this namespace(s) only", |
188 | | - 'limit' => "How many {$this->description}s to return", |
| 188 | + 'namespace' => "Show {$desc}s in this namespace(s) only", |
| 189 | + 'limit' => "How many {$desc}s to return", |
189 | 190 | 'continue' => 'When more results are available, use this to continue', |
190 | 191 | ); |
191 | 192 | } |
Index: trunk/phase3/includes/api/ApiQueryRandom.php |
— | — | @@ -149,8 +149,8 @@ |
150 | 150 | return array( |
151 | 151 | 'Get a set of random pages', |
152 | 152 | 'NOTE: Pages are listed in a fixed sequence, only the starting point is random. This means that if, for example, "Main Page" is the first ', |
153 | | - ' random page on your list, "List of fictional monkeys" will *always* be second, "List of people on stamps of Vanuatu" third, etc.', |
154 | | - 'NOTE: If the number of pages in the namespace is lower than rnlimit, you will get fewer pages. You will not get the same page twice.' |
| 153 | + ' random page on your list, "List of fictional monkeys" will *always* be second, "List of people on stamps of Vanuatu" third, etc', |
| 154 | + 'NOTE: If the number of pages in the namespace is lower than rnlimit, you will get fewer pages. You will not get the same page twice' |
155 | 155 | ); |
156 | 156 | } |
157 | 157 | |
Index: trunk/phase3/includes/api/ApiQuerySiteinfo.php |
— | — | @@ -486,7 +486,7 @@ |
487 | 487 | } |
488 | 488 | |
489 | 489 | public function getDescription() { |
490 | | - return 'Return general information about the site.'; |
| 490 | + return 'Return general information about the site'; |
491 | 491 | } |
492 | 492 | |
493 | 493 | public function getPossibleErrors() { |
Index: trunk/phase3/includes/api/ApiParse.php |
— | — | @@ -355,24 +355,25 @@ |
356 | 356 | } |
357 | 357 | |
358 | 358 | public function getParamDescription() { |
| 359 | + $p = $this->getModulePrefix(); |
359 | 360 | return array( |
360 | | - 'text' => 'Wikitext to parse.', |
361 | | - 'summary' => 'Summary to parse.', |
362 | | - 'redirects' => 'If the page parameter is set to a redirect, resolve it.', |
363 | | - 'title' => 'Title of page the text belongs to.', |
364 | | - 'page' => 'Parse the content of this page. Cannot be used together with text and title.', |
365 | | - 'pageid' => 'Parse the content of this page. Overrides page.', |
366 | | - 'oldid' => 'Parse the content of this revision. Overrides page and pageid.', |
367 | | - 'prop' => array( 'Which pieces of information to get.', |
368 | | - 'NOTE: Section tree is only generated if there are more than 4 sections, or if the __TOC__ keyword is present.' |
| 361 | + 'text' => 'Wikitext to parse', |
| 362 | + 'summary' => 'Summary to parse', |
| 363 | + 'redirects' => "If the {$p}page parameter is set to a redirect, resolve it", |
| 364 | + 'title' => 'Title of page the text belongs to', |
| 365 | + 'page' => "Parse the content of this page. Cannot be used together with {$p}text and {$p}title", |
| 366 | + 'pageid' => "Parse the content of this page. Overrides {$p}page", |
| 367 | + 'oldid' => "Parse the content of this revision. Overrides {$p}page and {$p}pageid", |
| 368 | + 'prop' => array( 'Which pieces of information to get', |
| 369 | + 'NOTE: Section tree is only generated if there are more than 4 sections, or if the __TOC__ keyword is present' |
369 | 370 | ), |
370 | | - 'pst' => array( 'Do a pre-save transform on the input before parsing it.', |
371 | | - 'Ignored if page, pageid or oldid is used.' |
| 371 | + 'pst' => array( 'Do a pre-save transform on the input before parsing it', |
| 372 | + 'Ignored if page, pageid or oldid is used' |
372 | 373 | ), |
373 | | - 'onlypst' => array( 'Do a pre-save transform (PST) on the input, but don\'t parse it.', |
374 | | - 'Returns the same wikitext, after a PST has been applied. Ignored if page, pageid or oldid is used.' |
| 374 | + 'onlypst' => array( 'Do a pre-save transform (PST) on the input, but don\'t parse it', |
| 375 | + 'Returns the same wikitext, after a PST has been applied. Ignored if page, pageid or oldid is used' |
375 | 376 | ), |
376 | | - 'uselang' => 'Which language to parse the request in.', |
| 377 | + 'uselang' => 'Which language to parse the request in', |
377 | 378 | 'section' => 'Only retrieve the content of this section number', |
378 | 379 | ); |
379 | 380 | } |
Index: trunk/phase3/includes/api/ApiQueryExtLinksUsage.php |
— | — | @@ -189,12 +189,13 @@ |
190 | 190 | } |
191 | 191 | |
192 | 192 | public function getParamDescription() { |
| 193 | + $p = $this->getModulePrefix(); |
193 | 194 | return array( |
194 | 195 | 'prop' => 'What pieces of information to include', |
195 | 196 | 'offset' => 'Used for paging. Use the value returned for "continue"', |
196 | 197 | 'protocol' => array( |
197 | | - 'Protocol of the url. If empty and euquery set, the protocol is http.', |
198 | | - 'Leave both this and euquery empty to list all external links' |
| 198 | + "Protocol of the url. If empty and {$p}query set, the protocol is http.", |
| 199 | + "Leave both this and {$p}query empty to list all external links" |
199 | 200 | ), |
200 | 201 | 'query' => 'Search string without protocol. See [[Special:LinkSearch]]. Leave empty to list all external links', |
201 | 202 | 'namespace' => 'The page namespace(s) to enumerate.', |
Index: trunk/phase3/includes/api/ApiQueryAllpages.php |
— | — | @@ -247,17 +247,18 @@ |
248 | 248 | } |
249 | 249 | |
250 | 250 | public function getParamDescription() { |
| 251 | + $p = $this->getModulePrefix(); |
251 | 252 | return array( |
252 | | - 'from' => 'The page title to start enumerating from.', |
253 | | - 'prefix' => 'Search for all page titles that begin with this value.', |
254 | | - 'namespace' => 'The namespace to enumerate.', |
255 | | - 'filterredir' => 'Which pages to list.', |
| 253 | + 'from' => 'The page title to start enumerating from', |
| 254 | + 'prefix' => 'Search for all page titles that begin with this value', |
| 255 | + 'namespace' => 'The namespace to enumerate', |
| 256 | + 'filterredir' => 'Which pages to list', |
256 | 257 | 'dir' => 'The direction in which to list', |
257 | 258 | 'minsize' => 'Limit to pages with at least this many bytes', |
258 | 259 | 'maxsize' => 'Limit to pages with at most this many bytes', |
259 | 260 | 'prtype' => 'Limit to protected pages only', |
260 | | - 'prlevel' => 'The protection level (must be used with apprtype= parameter)', |
261 | | - 'prfiltercascade' => 'Filter protections based on cascadingness (ignored when apprtype isn\'t set)', |
| 261 | + 'prlevel' => "The protection level (must be used with {$p}prtype= parameter)", |
| 262 | + 'prfiltercascade' => "Filter protections based on cascadingness (ignored when {$p}prtype isn't set)", |
262 | 263 | 'filterlanglinks' => 'Filter based on whether a page has langlinks', |
263 | 264 | 'limit' => 'How many total pages to return.' |
264 | 265 | ); |
Index: trunk/phase3/includes/api/ApiFormatWddx.php |
— | — | @@ -29,6 +29,7 @@ |
30 | 30 | } |
31 | 31 | |
32 | 32 | /** |
| 33 | + * API WDDX output formatter |
33 | 34 | * @ingroup API |
34 | 35 | */ |
35 | 36 | class ApiFormatWddx extends ApiFormatBase { |
Index: trunk/phase3/includes/api/ApiProtect.php |
— | — | @@ -179,7 +179,7 @@ |
180 | 180 | |
181 | 181 | public function getParamDescription() { |
182 | 182 | return array( |
183 | | - 'title' => 'Title of the page you want to (un)protect.', |
| 183 | + 'title' => 'Title of the page you want to (un)protect', |
184 | 184 | 'token' => 'A protect token previously retrieved through prop=info', |
185 | 185 | 'protections' => 'Pipe-separated list of protection levels, formatted action=group (e.g. edit=sysop)', |
186 | 186 | 'expiry' => array( 'Expiry timestamps. If only one timestamp is set, it\'ll be used for all protections.', |
— | — | @@ -194,7 +194,7 @@ |
195 | 195 | |
196 | 196 | public function getDescription() { |
197 | 197 | return array( |
198 | | - 'Change the protection level of a page.' |
| 198 | + 'Change the protection level of a page' |
199 | 199 | ); |
200 | 200 | } |
201 | 201 | |
Index: trunk/phase3/includes/api/ApiPurge.php |
— | — | @@ -99,7 +99,7 @@ |
100 | 100 | |
101 | 101 | public function getDescription() { |
102 | 102 | return array( |
103 | | - 'Purge the cache for the given titles.' |
| 103 | + 'Purge the cache for the given titles' |
104 | 104 | ); |
105 | 105 | } |
106 | 106 | |
Index: trunk/phase3/includes/api/ApiQueryBacklinks.php |
— | — | @@ -435,9 +435,9 @@ |
436 | 436 | |
437 | 437 | public function getParamDescription() { |
438 | 438 | $retval = array( |
439 | | - 'title' => 'Title to search.', |
440 | | - 'continue' => 'When more results are available, use this to continue.', |
441 | | - 'namespace' => 'The namespace to enumerate.', |
| 439 | + 'title' => 'Title to search', |
| 440 | + 'continue' => 'When more results are available, use this to continue', |
| 441 | + 'namespace' => 'The namespace to enumerate', |
442 | 442 | ); |
443 | 443 | if ( $this->getModuleName() != 'embeddedin' ) { |
444 | 444 | return array_merge( $retval, array( |
— | — | @@ -448,7 +448,7 @@ |
449 | 449 | } |
450 | 450 | return array_merge( $retval, array( |
451 | 451 | 'filterredir' => 'How to filter for redirects', |
452 | | - 'limit' => 'How many total pages to return.' |
| 452 | + 'limit' => 'How many total pages to return' |
453 | 453 | ) ); |
454 | 454 | } |
455 | 455 | |
Index: trunk/phase3/includes/api/ApiRollback.php |
— | — | @@ -98,8 +98,8 @@ |
99 | 99 | return array( |
100 | 100 | 'title' => 'Title of the page you want to rollback.', |
101 | 101 | 'user' => 'Name of the user whose edits are to be rolled back. If set incorrectly, you\'ll get a badtoken error.', |
102 | | - 'token' => 'A rollback token previously retrieved through prop=revisions', |
103 | | - 'summary' => 'Custom edit summary. If not set, default summary will be used.', |
| 102 | + 'token' => "A rollback token previously retrieved through {$this->getModulePrefix()}prop=revisions", |
| 103 | + 'summary' => 'Custom edit summary. If not set, default summary will be used', |
104 | 104 | 'markbot' => 'Mark the reverted edits and the revert as bot edits', |
105 | 105 | 'watchlist' => 'Unconditionally add or remove the page from your watchlist, use preferences or do not change watch', |
106 | 106 | ); |
— | — | @@ -108,7 +108,7 @@ |
109 | 109 | public function getDescription() { |
110 | 110 | return array( |
111 | 111 | 'Undo the last edit to the page. If the last user who edited the page made multiple edits in a row,', |
112 | | - 'they will all be rolled back.' |
| 112 | + 'they will all be rolled back' |
113 | 113 | ); |
114 | 114 | } |
115 | 115 | |
Index: trunk/phase3/includes/api/ApiQueryDeletedrevs.php |
— | — | @@ -306,9 +306,9 @@ |
307 | 307 | |
308 | 308 | public function getParamDescription() { |
309 | 309 | return array( |
310 | | - 'start' => 'The timestamp to start enumerating from. (1,2)', |
311 | | - 'end' => 'The timestamp to stop enumerating at. (1,2)', |
312 | | - 'dir' => 'The direction in which to enumerate. (1,2)', |
| 310 | + 'start' => 'The timestamp to start enumerating from (1,2)', |
| 311 | + 'end' => 'The timestamp to stop enumerating at (1,2)', |
| 312 | + 'dir' => 'The direction in which to enumerate (1,2)', |
313 | 313 | 'limit' => 'The maximum amount of revisions to list', |
314 | 314 | 'prop' => 'Which properties to get', |
315 | 315 | 'namespace' => 'Only list pages in this namespace (3)', |
— | — | @@ -328,7 +328,7 @@ |
329 | 329 | '2) List deleted contributions for the given user, sorted by timestamp (no titles specified)', |
330 | 330 | '3) List all deleted revisions in the given namespace, sorted by title and timestamp (no titles specified, druser not set)', |
331 | 331 | 'Certain parameters only apply to some modes and are ignored in others.', |
332 | | - 'For instance, a parameter marked (1) only applies to mode 1 and is ignored in modes 2 and 3.', |
| 332 | + 'For instance, a parameter marked (1) only applies to mode 1 and is ignored in modes 2 and 3', |
333 | 333 | ); |
334 | 334 | } |
335 | 335 | |
Index: trunk/phase3/includes/api/ApiUserrights.php |
— | — | @@ -54,7 +54,30 @@ |
55 | 55 | $this->getResult()->setIndexedTagName( $r['removed'], 'group' ); |
56 | 56 | $this->getResult()->addValue( null, $this->getModuleName(), $r ); |
57 | 57 | } |
| 58 | + |
| 59 | + private function getUser() { |
| 60 | + if ( $this->mUser !== null ) { |
| 61 | + return $this->mUser; |
| 62 | + } |
58 | 63 | |
| 64 | + $params = $this->extractRequestParams(); |
| 65 | + if ( is_null( $params['user'] ) ) { |
| 66 | + $this->dieUsageMsg( array( 'missingparam', 'user' ) ); |
| 67 | + } |
| 68 | + |
| 69 | + $form = new UserrightsPage; |
| 70 | + $status = $form->fetchUser( $params['user'] ); |
| 71 | + if ( !$status->isOK() ) { |
| 72 | + $errors = $status->getErrorsArray(); |
| 73 | + $this->dieUsageMsg( $errors[0] ); |
| 74 | + } else { |
| 75 | + $user = $status->value; |
| 76 | + } |
| 77 | + |
| 78 | + $this->mUser = $user; |
| 79 | + return $user; |
| 80 | + } |
| 81 | + |
59 | 82 | public function mustBePosted() { |
60 | 83 | return true; |
61 | 84 | } |
— | — | @@ -107,29 +130,6 @@ |
108 | 131 | return $this->getUser()->getName(); |
109 | 132 | } |
110 | 133 | |
111 | | - private function getUser() { |
112 | | - if ( $this->mUser !== null ) { |
113 | | - return $this->mUser; |
114 | | - } |
115 | | - |
116 | | - $params = $this->extractRequestParams(); |
117 | | - if ( is_null( $params['user'] ) ) { |
118 | | - $this->dieUsageMsg( array( 'missingparam', 'user' ) ); |
119 | | - } |
120 | | - |
121 | | - $form = new UserrightsPage; |
122 | | - $status = $form->fetchUser( $params['user'] ); |
123 | | - if ( !$status->isOK() ) { |
124 | | - $errors = $status->getErrorsArray(); |
125 | | - $this->dieUsageMsg( $errors[0] ); |
126 | | - } else { |
127 | | - $user = $status->value; |
128 | | - } |
129 | | - |
130 | | - $this->mUser = $user; |
131 | | - return $user; |
132 | | - } |
133 | | - |
134 | 134 | protected function getExamples() { |
135 | 135 | return array( |
136 | 136 | 'api.php?action=userrights&user=FooBot&add=bot&remove=sysop|bureaucrat&token=123ABC' |
Index: trunk/phase3/includes/api/ApiFormatPhp.php |
— | — | @@ -29,6 +29,7 @@ |
30 | 30 | } |
31 | 31 | |
32 | 32 | /** |
| 33 | + * API Serialized PHP output formatter |
33 | 34 | * @ingroup API |
34 | 35 | */ |
35 | 36 | class ApiFormatPhp extends ApiFormatBase { |
Index: trunk/phase3/includes/api/ApiDelete.php |
— | — | @@ -221,11 +221,12 @@ |
222 | 222 | } |
223 | 223 | |
224 | 224 | public function getParamDescription() { |
| 225 | + $p = $this->getModulePrefix(); |
225 | 226 | return array( |
226 | | - 'title' => 'Title of the page you want to delete. Cannot be used together with pageid', |
227 | | - 'pageid' => 'Page ID of the page you want to delete. Cannot be used together with title', |
| 227 | + 'title' => "Title of the page you want to delete. Cannot be used together with {$p}pageid", |
| 228 | + 'pageid' => "Page ID of the page you want to delete. Cannot be used together with {$p}title", |
228 | 229 | 'token' => 'A delete token previously retrieved through prop=info', |
229 | | - 'reason' => 'Reason for the deletion. If not set, an automatically generated reason will be used.', |
| 230 | + 'reason' => 'Reason for the deletion. If not set, an automatically generated reason will be used', |
230 | 231 | 'watch' => 'Add the page to your watchlist', |
231 | 232 | 'watchlist' => 'Unconditionally add or remove the page from your watchlist, use preferences or do not change watch', |
232 | 233 | 'unwatch' => 'Remove the page from your watchlist', |
— | — | @@ -235,7 +236,7 @@ |
236 | 237 | |
237 | 238 | public function getDescription() { |
238 | 239 | return array( |
239 | | - 'Delete a page.' |
| 240 | + 'Delete a page' |
240 | 241 | ); |
241 | 242 | } |
242 | 243 | |
Index: trunk/phase3/includes/api/ApiQueryBlocks.php |
— | — | @@ -269,14 +269,14 @@ |
270 | 270 | 'ids' => 'Pipe-separated list of block IDs to list (optional)', |
271 | 271 | 'users' => 'Pipe-separated list of users to search for (optional)', |
272 | 272 | 'ip' => array( 'Get all blocks applying to this IP or CIDR range, including range blocks.', |
273 | | - 'Cannot be used together with bkusers. CIDR ranges broader than /16 are not accepted.' ), |
| 273 | + 'Cannot be used together with bkusers. CIDR ranges broader than /16 are not accepted' ), |
274 | 274 | 'limit' => 'The maximum amount of blocks to list', |
275 | 275 | 'prop' => 'Which properties to get', |
276 | 276 | ); |
277 | 277 | } |
278 | 278 | |
279 | 279 | public function getDescription() { |
280 | | - return 'List all blocked users and IP addresses.'; |
| 280 | + return 'List all blocked users and IP addresses'; |
281 | 281 | } |
282 | 282 | |
283 | 283 | public function getPossibleErrors() { |
Index: trunk/phase3/includes/api/ApiGo.php |
— | — | @@ -33,10 +33,6 @@ |
34 | 34 | * @ingroup API |
35 | 35 | */ |
36 | 36 | class ApiGo extends ApiBase { |
37 | | - |
38 | | - /** |
39 | | - * Std ctor. |
40 | | - */ |
41 | 37 | public function __construct( $main, $action ) { |
42 | 38 | parent::__construct( $main, $action ); |
43 | 39 | } |
Index: trunk/phase3/includes/api/ApiQueryFilearchive.php |
— | — | @@ -217,13 +217,13 @@ |
218 | 218 | |
219 | 219 | public function getParamDescription() { |
220 | 220 | return array( |
221 | | - 'from' => 'The image title to start enumerating from.', |
222 | | - 'prefix' => 'Search for all image titles that begin with this value.', |
| 221 | + 'from' => 'The image title to start enumerating from', |
| 222 | + 'prefix' => 'Search for all image titles that begin with this value', |
223 | 223 | 'dir' => 'The direction in which to list', |
224 | 224 | 'minsize' => 'Limit to images with at least this many bytes', |
225 | 225 | 'maxsize' => 'Limit to images with at most this many bytes', |
226 | | - 'limit' => 'How many total images to return.', |
227 | | - 'sha1' => 'SHA1 hash of image. Overrides sha1base36', |
| 226 | + 'limit' => 'How many total images to return', |
| 227 | + 'sha1' => "SHA1 hash of image. Overrides {$this->getModulePrefix()}sha1base36", |
228 | 228 | 'sha1base36' => 'SHA1 hash of image in base 36 (used in MediaWiki)', |
229 | 229 | 'prop' => 'Which properties to get', |
230 | 230 | ); |
Index: trunk/phase3/includes/api/ApiDisabled.php |
— | — | @@ -61,7 +61,7 @@ |
62 | 62 | |
63 | 63 | public function getDescription() { |
64 | 64 | return array( |
65 | | - 'This module has been disabled.' |
| 65 | + 'This module has been disabled' |
66 | 66 | ); |
67 | 67 | } |
68 | 68 | |
Index: trunk/phase3/includes/api/ApiFormatYaml.php |
— | — | @@ -29,6 +29,7 @@ |
30 | 30 | } |
31 | 31 | |
32 | 32 | /** |
| 33 | + * API YAML output formatter |
33 | 34 | * @ingroup API |
34 | 35 | */ |
35 | 36 | class ApiFormatYaml extends ApiFormatBase { |
Index: trunk/phase3/includes/api/ApiQueryCategoryMembers.php |
— | — | @@ -258,16 +258,17 @@ |
259 | 259 | |
260 | 260 | public function getParamDescription() { |
261 | 261 | global $wgMiserMode; |
| 262 | + $p = $this->getModulePrefix(); |
262 | 263 | $desc = array( |
263 | 264 | 'title' => 'Which category to enumerate (required). Must include Category: prefix', |
264 | 265 | 'prop' => 'What pieces of information to include', |
265 | 266 | 'namespace' => 'Only include pages in these namespaces', |
266 | 267 | 'sort' => 'Property to sort by', |
267 | 268 | 'dir' => 'In which direction to sort', |
268 | | - 'start' => 'Timestamp to start listing from. Can only be used with cmsort=timestamp', |
269 | | - 'end' => 'Timestamp to end listing at. Can only be used with cmsort=timestamp', |
270 | | - 'startsortkey' => 'Sortkey to start listing from. Can only be used with cmsort=sortkey', |
271 | | - 'endsortkey' => 'Sortkey to end listing at. Can only be used with cmsort=sortkey', |
| 269 | + 'start' => "Timestamp to start listing from. Can only be used with {$p}sort=timestamp", |
| 270 | + 'end' => "Timestamp to end listing at. Can only be used with {$p}sort=timestamp", |
| 271 | + 'startsortkey' => "Sortkey to start listing from. Can only be used with {$p}sort=sortkey", |
| 272 | + 'endsortkey' => "Sortkey to end listing at. Can only be used with {$p}sort=sortkey", |
272 | 273 | 'continue' => 'For large categories, give the value retured from previous query', |
273 | 274 | 'limit' => 'The maximum number of pages to return.', |
274 | 275 | ); |
— | — | @@ -275,7 +276,7 @@ |
276 | 277 | $desc['namespace'] = array( |
277 | 278 | $desc['namespace'], |
278 | 279 | 'NOTE: Due to $wgMiserMode, using this may result in fewer than "limit" results', |
279 | | - 'returned before continuing; in extreme cases, zero results may be returned.', |
| 280 | + 'returned before continuing; in extreme cases, zero results may be returned', |
280 | 281 | ); |
281 | 282 | } |
282 | 283 | return $desc; |
Index: trunk/phase3/includes/api/ApiEditPage.php |
— | — | @@ -433,6 +433,7 @@ |
434 | 434 | } |
435 | 435 | |
436 | 436 | protected function getParamDescription() { |
| 437 | + $p = $this->getModulePrefix(); |
437 | 438 | return array( |
438 | 439 | 'title' => 'Page title', |
439 | 440 | 'section' => 'Section number. 0 for the top section, \'new\' for a new section', |
— | — | @@ -446,7 +447,7 @@ |
447 | 448 | 'Used to detect edit conflicts; leave unset to ignore conflicts.' |
448 | 449 | ), |
449 | 450 | 'starttimestamp' => array( 'Timestamp when you obtained the edit token.', |
450 | | - 'Used to detect edit conflicts; leave unset to ignore conflicts.' |
| 451 | + 'Used to detect edit conflicts; leave unset to ignore conflicts' |
451 | 452 | ), |
452 | 453 | 'recreate' => 'Override any errors about the article having been deleted in the meantime', |
453 | 454 | 'createonly' => 'Don\'t edit the page if it exists already', |
— | — | @@ -456,11 +457,11 @@ |
457 | 458 | 'watchlist' => 'Unconditionally add or remove the page from your watchlist, use preferences or do not change watch', |
458 | 459 | 'captchaid' => 'CAPTCHA ID from previous request', |
459 | 460 | 'captchaword' => 'Answer to the CAPTCHA', |
460 | | - 'md5' => array( 'The MD5 hash of the text parameter, or the prependtext and appendtext parameters concatenated.', |
| 461 | + 'md5' => array( "The MD5 hash of the {$p}text parameter, or the {$p}prependtext and {$p}appendtext parameters concatenated.", |
461 | 462 | 'If set, the edit won\'t be done unless the hash is correct' ), |
462 | | - 'prependtext' => 'Add this text to the beginning of the page. Overrides text.', |
463 | | - 'appendtext' => 'Add this text to the end of the page. Overrides text', |
464 | | - 'undo' => 'Undo this revision. Overrides text, prependtext and appendtext', |
| 463 | + 'prependtext' => "Add this text to the beginning of the page. Overrides {$p}text", |
| 464 | + 'appendtext' => "Add this text to the end of the page. Overrides {$p}text", |
| 465 | + 'undo' => "Undo this revision. Overrides {$p}text, {$p}prependtext and {$p}appendtext", |
465 | 466 | 'undoafter' => 'Undo all revisions from undo to this one. If not set, just undo one revision', |
466 | 467 | ); |
467 | 468 | } |
Index: trunk/phase3/includes/api/ApiQueryAllimages.php |
— | — | @@ -179,13 +179,13 @@ |
180 | 180 | |
181 | 181 | public function getParamDescription() { |
182 | 182 | return array( |
183 | | - 'from' => 'The image title to start enumerating from.', |
184 | | - 'prefix' => 'Search for all image titles that begin with this value.', |
| 183 | + 'from' => 'The image title to start enumerating from', |
| 184 | + 'prefix' => 'Search for all image titles that begin with this value', |
185 | 185 | 'dir' => 'The direction in which to list', |
186 | 186 | 'minsize' => 'Limit to images with at least this many bytes', |
187 | 187 | 'maxsize' => 'Limit to images with at most this many bytes', |
188 | | - 'limit' => 'How many total images to return.', |
189 | | - 'sha1' => 'SHA1 hash of image. Overrides sha1base36', |
| 188 | + 'limit' => 'How many images in total to return', |
| 189 | + 'sha1' => "SHA1 hash of image. Overrides {$this->getModulePrefix()}sha1base36", |
190 | 190 | 'sha1base36' => 'SHA1 hash of image in base 36 (used in MediaWiki)', |
191 | 191 | 'prop' => 'Which properties to get', |
192 | 192 | ); |
Index: trunk/phase3/includes/api/ApiQueryAllmessages.php |
— | — | @@ -165,7 +165,7 @@ |
166 | 166 | } |
167 | 167 | |
168 | 168 | public function getDescription() { |
169 | | - return 'Return messages from this site.'; |
| 169 | + return 'Return messages from this site'; |
170 | 170 | } |
171 | 171 | |
172 | 172 | protected function getExamples() { |
Index: trunk/phase3/includes/api/ApiFormatTxt.php |
— | — | @@ -29,6 +29,7 @@ |
30 | 30 | } |
31 | 31 | |
32 | 32 | /** |
| 33 | + * API Text output formatter |
33 | 34 | * @ingroup API |
34 | 35 | */ |
35 | 36 | class ApiFormatTxt extends ApiFormatBase { |
Index: trunk/phase3/RELEASE-NOTES |
— | — | @@ -175,6 +175,7 @@ |
176 | 176 | * (bug 23458) Add support for pageid parameter to action=parse requests |
177 | 177 | * (bug 23460) Parse action should have a section option |
178 | 178 | * (bug 21346) Make deleted images searchable by hash |
| 179 | +* (bug 23461) Normalise usage of parameter names in parameter descriptions |
179 | 180 | |
180 | 181 | === Languages updated in 1.17 === |
181 | 182 | |