Jump to content

Help With Round()


MrXander

Recommended Posts

Hi Guys,

 

This might be a really dim question, but I need assistance with the round() function.

 

I am trying to show a rounded figure of, for example $3.50, but using round, it is dropping the last zero.

 

The line of code being used is:

$price1 = round($personal1 * $rate, 2);

 

Is there anyway to avoid this and display the last zero?

 

Thank you!

Link to comment
https://forums.phpfreaks.com/topic/268658-help-with-round/
Share on other sites

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.