From bfcd95c8e5b8f88b2604cc017c7b090a6d10cfe8 Mon Sep 17 00:00:00 2001 From: Daniel Cannon Date: Wed, 24 Oct 2007 19:34:29 +0000 Subject: [PATCH] (bug 11721) API: Use a different title for results than for the help page. --- RELEASE-NOTES | 1 + includes/api/ApiFormatBase.php | 6 +++++- includes/api/ApiMain.php | 3 ++- 3 files changed, 8 insertions(+), 2 deletions(-) diff --git a/RELEASE-NOTES b/RELEASE-NOTES index 53d680d797..1472c5b8fa 100644 --- a/RELEASE-NOTES +++ b/RELEASE-NOTES @@ -140,6 +140,7 @@ Full API documentation is available at http://www.mediawiki.org/wiki/API * Add rctype parameter to list=recentchanges that filters by type * Add apprtype and apprlevel parameters to filter list=allpages by protection types and levels * Add apdir parameter to enable listing all pages from Z to A +* (bug 11721) Use a different title for results than for the help page. === Languages updated in 1.12 === diff --git a/includes/api/ApiFormatBase.php b/includes/api/ApiFormatBase.php index dc5b7444f7..04de86166c 100644 --- a/includes/api/ApiFormatBase.php +++ b/includes/api/ApiFormatBase.php @@ -111,7 +111,11 @@ abstract class ApiFormatBase extends ApiBase { - MediaWiki API +mUnescapeAmps) { +?> MediaWiki API + MediaWiki API Result + mPrinter; $printer->profileIn(); - $printer->initPrinter($isError); /* If the help message is requested in the default (xmlfm) format, * tell the printer not to escape ampersands so that our links do @@ -329,6 +328,8 @@ class ApiMain extends ApiBase { $printer->setUnescapeAmps ( $this->mAction == 'help' && $params['format'] == ApiMain::API_DEFAULT_FORMAT ); + $printer->initPrinter($isError); + $printer->execute(); $printer->closePrinter(); $printer->profileOut(); -- 2.20.1