Articles tagged with "localization", sorted by date (updated)X
Displaying 1-1 of 1 result(s).

Custom Number Formatting or Decimal Separators and i18n

Updated 5 years ago by c@cbaTutorials8 comments – viewed 56,835 times – ( +7 / -1 ) – version 1.1
By default, the decimal separator in php (also in mysql) is a dot (.). So when we work with floats in Yii (in calculations, validation, sql statements etc.), the decimal separator has to be a dot. If we want to use for example a comma (,) as the decimal separator, that is if we want to display numbers and enable users to enter numbers with a comma before the decimals, we have to...