PHP math question -


Let's say I divide it by 100 times so that the percent is received 93.33333333333333 How can I show it using 93.3% php?

Here is the code.

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

The sprintf function is created for this (this See also)):

  resonant sprinkle ('% .1f %%', $ percent);  

Comments

Popular posts from this blog

oracle - The fastest way to check if some records in a database table? -

php - multilevel menu with multilevel array -

jQuery UI: Datepicker month format -