Plural for russian

/* echo get_plural_form(42, array('арбуз', 'арбуза', 'арбузов')); */ function get_plural_form($n, $txt) { return $n%10==1&&$n%100!=11?$txt[0]:($n%10>=2&&$n%10<=4&&($n%100<10||$n%100>=20)?$txt[1]:$txt[2]); }

Be the first to comment

You can use [html][/html], [css][/css], [php][/php] and more to embed the code. Urls are automatically hyperlinked. Line breaks and paragraphs are automatically generated.