Forum Moderators: coopster

Message Too Old, No Replies

Rounding Currency values

         

asantos

12:48 am on Aug 18, 2006 (gmt 0)

10+ Year Member



Hi,
im developing a script that returns some prices.. and then calculates some monthly payments.

The problem is that sometimes the values have cent values... and i get values such as this ones:

* 500,1 (instead of 500,10)
* 400 (instead of 400,00)

How can i solve this?

barns101

1:22 am on Aug 18, 2006 (gmt 0)

10+ Year Member



You need to use number_format [php.net].

whoisgregg

3:00 pm on Aug 18, 2006 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Or money_format [php.net]... :)

asantos

4:48 pm on Aug 18, 2006 (gmt 0)

10+ Year Member



thanks!

asantos

4:50 pm on Aug 18, 2006 (gmt 0)

10+ Year Member



btw, is it just me or is there a problem with the email notifications of WebmasterWorld? im not receiving anything

coopster

3:35 pm on Aug 22, 2006 (gmt 0)

WebmasterWorld Administrator 10+ Year Member



It's just you.

Just kidding ;)

Issue is known and still being addressed:
[webmasterworld.com...]