From b98f2a5a711f486f0cd8b0abd9f583034058d167 Mon Sep 17 00:00:00 2001 From: Bryan Tong Minh Date: Tue, 23 Nov 2010 22:05:27 +0000 Subject: [PATCH] (bug 25174) Add equal sign to boolean parameters in examples, so that the examples work immediately when posted --- includes/api/ApiBlock.php | 2 +- includes/api/ApiEditPage.php | 2 +- includes/api/ApiImport.php | 2 +- includes/api/ApiMove.php | 2 +- includes/api/ApiProtect.php | 2 +- includes/api/ApiQueryAllLinks.php | 2 +- includes/api/ApiQueryDeletedrevs.php | 2 +- includes/api/ApiQueryLangLinks.php | 2 +- includes/api/ApiQuerySiteinfo.php | 2 +- includes/api/ApiQueryWatchlist.php | 4 ++-- includes/api/ApiWatch.php | 2 +- 11 files changed, 12 insertions(+), 12 deletions(-) diff --git a/includes/api/ApiBlock.php b/includes/api/ApiBlock.php index 3055007d7a..25506ac0a1 100644 --- a/includes/api/ApiBlock.php +++ b/includes/api/ApiBlock.php @@ -194,7 +194,7 @@ class ApiBlock extends ApiBase { protected function getExamples() { return array( 'api.php?action=block&user=123.5.5.12&expiry=3%20days&reason=First%20strike', - 'api.php?action=block&user=Vandal&expiry=never&reason=Vandalism&nocreate&autoblock&noemail' + 'api.php?action=block&user=Vandal&expiry=never&reason=Vandalism&nocreate=&autoblock=&noemail=' ); } diff --git a/includes/api/ApiEditPage.php b/includes/api/ApiEditPage.php index 0a88371559..87f9313ad6 100644 --- a/includes/api/ApiEditPage.php +++ b/includes/api/ApiEditPage.php @@ -514,7 +514,7 @@ class ApiEditPage extends ApiBase { 'Edit a page (anonymous user):', ' api.php?action=edit&title=Test&summary=test%20summary&text=article%20content&basetimestamp=20070824123454&token=%2B\\', 'Prepend __NOTOC__ to a page (anonymous user):', - ' api.php?action=edit&title=Test&summary=NOTOC&minor&prependtext=__NOTOC__%0A&basetimestamp=20070824123454&token=%2B\\', + ' api.php?action=edit&title=Test&summary=NOTOC&minor=&prependtext=__NOTOC__%0A&basetimestamp=20070824123454&token=%2B\\', 'Undo r13579 through r13585 with autosummary (anonymous user):', ' api.php?action=edit&title=Test&undo=13585&undoafter=13579&basetimestamp=20070824123454&token=%2B\\', ); diff --git a/includes/api/ApiImport.php b/includes/api/ApiImport.php index 8c031061b4..39b991ab03 100644 --- a/includes/api/ApiImport.php +++ b/includes/api/ApiImport.php @@ -165,7 +165,7 @@ class ApiImport extends ApiBase { protected function getExamples() { return array( 'Import [[meta:Help:Parserfunctions]] to namespace 100 with full history:', - ' api.php?action=import&interwikisource=meta&interwikipage=Help:ParserFunctions&namespace=100&fullhistory&token=123ABC', + ' api.php?action=import&interwikisource=meta&interwikipage=Help:ParserFunctions&namespace=100&fullhistory=&token=123ABC', ); } diff --git a/includes/api/ApiMove.php b/includes/api/ApiMove.php index 13b54da8f6..c5cbe5ecec 100644 --- a/includes/api/ApiMove.php +++ b/includes/api/ApiMove.php @@ -243,7 +243,7 @@ class ApiMove extends ApiBase { protected function getExamples() { return array( - 'api.php?action=move&from=Exampel&to=Example&token=123ABC&reason=Misspelled%20title&movetalk&noredirect' + 'api.php?action=move&from=Exampel&to=Example&token=123ABC&reason=Misspelled%20title&movetalk=&noredirect=' ); } diff --git a/includes/api/ApiProtect.php b/includes/api/ApiProtect.php index 6a1658c8d6..7f2b83d1ff 100644 --- a/includes/api/ApiProtect.php +++ b/includes/api/ApiProtect.php @@ -217,7 +217,7 @@ class ApiProtect extends ApiBase { protected function getExamples() { return array( - 'api.php?action=protect&title=Main%20Page&token=123ABC&protections=edit=sysop|move=sysop&cascade&expiry=20070901163000|never', + 'api.php?action=protect&title=Main%20Page&token=123ABC&protections=edit=sysop|move=sysop&cascade=&expiry=20070901163000|never', 'api.php?action=protect&title=Main%20Page&token=123ABC&protections=edit=all|move=all&reason=Lifting%20restrictions' ); } diff --git a/includes/api/ApiQueryAllLinks.php b/includes/api/ApiQueryAllLinks.php index 537b2420f1..7f619c53db 100644 --- a/includes/api/ApiQueryAllLinks.php +++ b/includes/api/ApiQueryAllLinks.php @@ -224,7 +224,7 @@ class ApiQueryAllLinks extends ApiQueryGeneratorBase { protected function getExamples() { return array( - 'api.php?action=query&list=alllinks&alunique&alfrom=B', + 'api.php?action=query&list=alllinks&alunique=&alfrom=B', ); } diff --git a/includes/api/ApiQueryDeletedrevs.php b/includes/api/ApiQueryDeletedrevs.php index e6213fcd91..936e5365df 100644 --- a/includes/api/ApiQueryDeletedrevs.php +++ b/includes/api/ApiQueryDeletedrevs.php @@ -367,7 +367,7 @@ class ApiQueryDeletedrevs extends ApiQueryBase { 'List the first 50 deleted revisions in the main namespace (mode 3):', ' api.php?action=query&list=deletedrevs&drdir=newer&drlimit=50', 'List the first 50 deleted pages in the Talk namespace (mode 3):', - ' api.php?action=query&list=deletedrevs&drdir=newer&drlimit=50&drnamespace=1&drunique', + ' api.php?action=query&list=deletedrevs&drdir=newer&drlimit=50&drnamespace=1&drunique=', ); } diff --git a/includes/api/ApiQueryLangLinks.php b/includes/api/ApiQueryLangLinks.php index 3f7e4fd777..58029ff24e 100644 --- a/includes/api/ApiQueryLangLinks.php +++ b/includes/api/ApiQueryLangLinks.php @@ -141,7 +141,7 @@ class ApiQueryLangLinks extends ApiQueryBase { protected function getExamples() { return array( 'Get interlanguage links from the [[Main Page]]:', - ' api.php?action=query&prop=langlinks&titles=Main%20Page&redirects', + ' api.php?action=query&prop=langlinks&titles=Main%20Page&redirects=', ); } diff --git a/includes/api/ApiQuerySiteinfo.php b/includes/api/ApiQuerySiteinfo.php index 5eec4dec80..9e856888f9 100644 --- a/includes/api/ApiQuerySiteinfo.php +++ b/includes/api/ApiQuerySiteinfo.php @@ -526,7 +526,7 @@ class ApiQuerySiteinfo extends ApiQueryBase { return array( 'api.php?action=query&meta=siteinfo&siprop=general|namespaces|namespacealiases|statistics', 'api.php?action=query&meta=siteinfo&siprop=interwikimap&sifilteriw=local', - 'api.php?action=query&meta=siteinfo&siprop=dbrepllag&sishowalldb', + 'api.php?action=query&meta=siteinfo&siprop=dbrepllag&sishowalldb=', ); } diff --git a/includes/api/ApiQueryWatchlist.php b/includes/api/ApiQueryWatchlist.php index 547ce8c082..eef8fb613a 100644 --- a/includes/api/ApiQueryWatchlist.php +++ b/includes/api/ApiQueryWatchlist.php @@ -412,9 +412,9 @@ class ApiQueryWatchlist extends ApiQueryGeneratorBase { return array( 'api.php?action=query&list=watchlist', 'api.php?action=query&list=watchlist&wlprop=ids|title|timestamp|user|comment', - 'api.php?action=query&list=watchlist&wlallrev&wlprop=ids|title|timestamp|user|comment', + 'api.php?action=query&list=watchlist&wlallrev=&wlprop=ids|title|timestamp|user|comment', 'api.php?action=query&generator=watchlist&prop=info', - 'api.php?action=query&generator=watchlist&gwlallrev&prop=revisions&rvprop=timestamp|user', + 'api.php?action=query&generator=watchlist&gwlallrev=&prop=revisions&rvprop=timestamp|user', 'api.php?action=query&list=watchlist&wlowner=Bob_Smith&wltoken=d8d562e9725ea1512894cdab28e5ceebc7f20237' ); } diff --git a/includes/api/ApiWatch.php b/includes/api/ApiWatch.php index 4ad1da57da..81ded18076 100644 --- a/includes/api/ApiWatch.php +++ b/includes/api/ApiWatch.php @@ -108,7 +108,7 @@ class ApiWatch extends ApiBase { protected function getExamples() { return array( 'api.php?action=watch&title=Main_Page', - 'api.php?action=watch&title=Main_Page&unwatch', + 'api.php?action=watch&title=Main_Page&unwatch=', ); } -- 2.20.1