Forum
Calc Builder Support
Calc Builder supportForums
No se permite escribir sin estar logado. Por favor, login
Re: comma formatting 18.10.2011 21:45
Hello,
if your users introduce commas when writting numbers, you should format the numbers before starting math to provide correct numbers to php functions. We suggest starting using
str_replace
function to replace all commas introduced at input for dots.
Then you could make all calculations.
And you could show results formatted as your users expect to see the numbers using number_format to specify thousand and decimal separators.
Hope this helps
Moonsoft Team
www.moonsoft.es
if your users introduce commas when writting numbers, you should format the numbers before starting math to provide correct numbers to php functions. We suggest starting using
str_replace
function to replace all commas introduced at input for dots.
Then you could make all calculations.
And you could show results formatted as your users expect to see the numbers using number_format to specify thousand and decimal separators.
Hope this helps
Moonsoft Team
www.moonsoft.es