* Also put the wgGrammarForms from the Wikimedia configuration in here, so everything is in one place. Bonus with this setup is that there will be a little less work for Wikimedia shell operators, as the wgGrammarForms configuration is now accessible to i18n committers. * Header for WikimediaMessages.php, and add myself to extension credits. WARNING to Wikimedia shell operators: the whole section "wgGrammarForms" in InitialiseSettings.php.html should be remove after updating to this version. It will most probably overrule all settings in WikimediaMessages because of "'default' => array()"
23 lines
459 B
PHP
23 lines
459 B
PHP
<?php
|
|
|
|
/** Hungarian localisation for MediaWiki
|
|
*
|
|
* @ingroup Language
|
|
*/
|
|
class LanguageHu extends Language {
|
|
function convertGrammar( $word, $case ) {
|
|
global $wgGrammarForms;
|
|
if ( isset($wgGrammarForms[$this->getCode()][$case][$word]) ) {
|
|
return $wgGrammarForms[$this->getCode()][$case][$word];
|
|
}
|
|
|
|
switch ( $case ) {
|
|
case 'rol':
|
|
return $word . 'ról';
|
|
case 'ba':
|
|
return $word . 'ba';
|
|
case 'k':
|
|
return $word . 'k';
|
|
}
|
|
}
|
|
}
|