MediaWiki  REL1_20
LanguageMt.php
Go to the documentation of this file.
00001 <?php
00030 class LanguageMt extends Language {
00031 
00037         function convertPlural( $count, $forms ) {
00038                 if ( !count( $forms ) ) { return ''; }
00039 
00040                 $forms = $this->preConvertPlural( $forms, 4 );
00041 
00042                 if ( $count == 1 ) $index = 0;
00043                 elseif ( $count == 0 || ( $count % 100 > 1 && $count % 100 < 11 ) ) $index = 1;
00044                 elseif ( $count % 100 > 10 && $count % 100 < 20 ) $index = 2;
00045                 else $index = 3;
00046                 return $forms[$index];
00047         }
00048 }