$entry['lang'] = $bits[0];
if ( $title ) {
$entry['url'] = wfExpandUrl( $title->getFullURL(), PROTO_CURRENT );
+ // localised language name in user language (maybe set by uselang=)
+ $entry['langname'] = Language::fetchLanguageName( $title->getInterwiki(), $this->getLanguage()->getCode() );
+ // native language name
+ $entry['autonym'] = Language::fetchLanguageName( $title->getInterwiki() );
}
ApiResult::setContent( $entry, $bits[1] );
$result[] = $entry;
public function getParamDescription() {
$p = $this->getModulePrefix();
+ $wikitext = CONTENT_MODEL_WIKITEXT;
return array(
'text' => "Text to parse. Use {$p}title or {$p}contentmodel to control the content model",
$p = $this->getModulePrefix();
return array(
- 'Parses content and returns parser output',
+ 'Parses content and returns parser output.',
'See the various prop-Modules of action=query to get information from the current' .
- 'version of a page',
+ 'version of a page.',
'There are several ways to specify the text to parse:',
"1) Specify a page or revision, using {$p}page, {$p}pageid, or {$p}oldid.",
"2) Specify content explicitly, using {$p}text, {$p}title, and {$p}contentmodel.",