Jump to content

[SOLVED] Format a number, but INCLUDE trailing 0's?


DaveLinger

Recommended Posts

So I have an assortment of numbers coming in, they're all zero point something. I want them to round to zero point number number - like currency... $0.XX. Problem I'm running into is that when I do round($var, 2), it cuts off trailing zeros, so some numbers end up as $0.X, because the next number would have been a zero. How do I keep that on there?

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.