schrenzor
(Rene Ponudic)
1
When I add a language var to my XMLMessageSource with the ChoiceFormat option there is missing a whitespace:
<entry id="amountTables">1#{amount} Table|n>1#{amount} Tables</entry>
96Tables
If I add a second whitespace between placeholder and text, everything is correct:
<entry id="amountTables">1#{amount} Table|n>1#{amount} Tables</entry>
96 Tables
qiang
(Qiang Xue)
2
This is weird. Could you please insert an echo statement in line 62 of CChoiceFormat.php and see what $message is being returned?
schrenzor
(Rene Ponudic)
3
Everything seems to be OK there… I've var_dump'ed the variable $messages:
string '{amount} Tables' (length=15)
qiang
(Qiang Xue)
4
Then it should work as expected. If you check YiiBase::t(), you will see the next method is strtr() of the message…