Forum Moderators: coopster

Message Too Old, No Replies

Need to shorten long integer

From 0.013234534 to 0.013

         

twist

5:57 am on Feb 1, 2004 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



I know this is simple enough, I know there is a function that does this but for the life of me I cant remember what it is. So instead of searching for the next hour if someone could give me a hand I would be very thankful.

jatar_k

8:06 am on Feb 1, 2004 (gmt 0)

WebmasterWorld Administrator 10+ Year Member



echo round(0.013234534, 3);

twist

9:02 am on Feb 1, 2004 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



I knew it would be something simple, thanks.

ams_david

9:09 am on Feb 1, 2004 (gmt 0)

10+ Year Member



and also:

number_format(0.013234534, 3) = 0.013