Function format_plural is useable only if language has only one plural case (English), but I need to use it for Czech language what has (like most languages from slovenian and roman family) more cases for plural.
For example English has two cases:
- 1: bed
- 2-∞: beds
But in Czech we needs more cases for the same word:
- 1: postel
- 2-4: postele
- 5-∞: postelí
And the schema is usually different for different words. (Mistake, it is the same for all words in one language, but different between languages.)
Is there some API in core or in some module that can translate this (for Americans crazy :-)) cases?
format_plural
and this issue. I haven't tried it but it looks like you might use something likeformat_plural('1 bed', '@count beds', $count)
and then add translations like'1 bed' => '1 postel', '@count[1] beds' => '@count[1] postele', '@count[2] beds' => '@count[2] postelí
. Or similar