Jump to content

Round Whole Numbers in Increments?


ShoeLace1291

Recommended Posts

I was wondering if there was a way to round whole numbers in increments.  I need to make a progress bar based on percentages and for every ten percent of progress that is made, I want to add a bar.  So for example:

 

38% would display four bars

21% would display two bars

15% would display one bar.

 

Are there any PHP functions like this?

Link to comment
https://forums.phpfreaks.com/topic/217422-round-whole-numbers-in-increments/
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.