5dec67e6433215e713473af39d0b39694f9b44e2
[lhc/web/wiklou.git] / languages / classes / LanguageKu_ku.php
1 <?php
2
3 /** Kurdish
4 *
5 * @ingroup Language
6 */
7 class LanguageKu_ku extends Language {
8
9 /** # Convert from the nominative form of a noun to some other case
10 # Invoked with {{GRAMMAR:case|word}}
11 /**
12 * Cases:
13 *
14 * From Kazakh interface, not needed at the moment, maybe later
15 */
16 function convertGrammar( $word, $case ) {
17 return $word;
18 }
19
20 /**
21 * Avoid grouping whole numbers between 0 to 9999
22 */
23 function commafy( $_ ) {
24
25 if ( !preg_match( '/^\d{1,4}$/', $_ ) ) {
26 return strrev( (string)preg_replace( '/(\d{3})(?=\d)(?!\d*\.)/', '$1,', strrev($_) ) );
27 } else {
28 return $_;
29 }
30 }
31 }