From 82b34d1b0375acfa24e0edcf17f80af1e5814bc9 Mon Sep 17 00:00:00 2001 From: Roan Kattouw Date: Sat, 31 Jan 2009 16:29:15 +0000 Subject: [PATCH] API: (bug 17239) Added prop=displaytitle to action=parse --- RELEASE-NOTES | 1 + includes/api/ApiParse.php | 7 +++++-- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/RELEASE-NOTES b/RELEASE-NOTES index e111b80dab..7f9976c325 100644 --- a/RELEASE-NOTES +++ b/RELEASE-NOTES @@ -139,6 +139,7 @@ it from source control: http://www.mediawiki.org/wiki/Download_from_SVN * (bug 17182) Fix pretty printer so URLs with parentheses in them are autolinked correctly * (bug 17224) Added siprop=rightsinfo to meta=siteinfo +* (bug 17239) Added prop=displaytitle to action=parse === Languages updated in 1.15 === diff --git a/includes/api/ApiParse.php b/includes/api/ApiParse.php index 50b19e2169..eb599a303a 100644 --- a/includes/api/ApiParse.php +++ b/includes/api/ApiParse.php @@ -151,6 +151,8 @@ class ApiParse extends ApiBase { $result_array['externallinks'] = array_keys($p_result->getExternalLinks()); if(isset($prop['sections'])) $result_array['sections'] = $p_result->getSections(); + if(isset($prop['displaytitle'])) + $result_array['displaytitle'] = $p_result->getDisplayTitle(); if(!is_null($oldid)) $result_array['revid'] = $oldid; @@ -223,7 +225,7 @@ class ApiParse extends ApiBase { 'redirects' => false, 'oldid' => null, 'prop' => array( - ApiBase :: PARAM_DFLT => 'text|langlinks|categories|links|templates|images|externallinks|sections|revid', + ApiBase :: PARAM_DFLT => 'text|langlinks|categories|links|templates|images|externallinks|sections|revid|displaytitle', ApiBase :: PARAM_ISMULTI => true, ApiBase :: PARAM_TYPE => array( 'text', @@ -234,7 +236,8 @@ class ApiParse extends ApiBase { 'images', 'externallinks', 'sections', - 'revid' + 'revid', + 'displaytitle', ) ), 'pst' => false, -- 2.20.1