0
   

How much is 14 / 15 times by 100 using PHP

 
 
simy202
 
Reply Sun 23 Jan, 2011 07:07 pm
I divide 14 / 15 times it by 100 to get the percentage which is 93.33333333333333 how can I display it as 93.3% using php?

Here is the code.

$percent = ($avg / 15) * 100;

Any One could provide me some hints about this PHP Math will be highly appreciated.
  • Topic Stats
  • Top Replies
  • Link to this Topic
Type: Question • Score: 0 • Views: 1,771 • Replies: 1
No top replies

 
parados
 
  2  
Reply Sun 23 Jan, 2011 08:25 pm
@simy202,
Check out "number_format" in the php manual
0 Replies
 
 

Related Topics

Clone of Micosoft Office - Question by Advocate
Do You Turn Off Your Computer at Night? - Discussion by Phoenix32890
The "Death" of the Computer Mouse - Discussion by Phoenix32890
Windows 10... - Discussion by Region Philbis
Surface Pro 3: What do you think? - Question by neologist
Windows 8 tips thread - Discussion by Wilso
GOOGLE CHROME - Question by Setanta
.Net and Firefox... - Discussion by gungasnake
Hacking a computer and remote access - Discussion by trying2learn
 
  1. Forums
  2. » How much is 14 / 15 times by 100 using PHP
Copyright © 2020 MadLab, LLC :: Terms of Service :: Privacy Policy :: Page generated in 0.04 seconds on 08/11/2020 at 07:18:54