Hello everyone.
I have the following variable declared:
$v1_percent = ($v1_total/$total);
The result of this is: 0.33333333333333.
I would like this to show up as 33%.
Any suggestions?
Thanks in advance! Jon
$v1_percent = round(($v1_total/$total) * 100);
would that work?
this did it for me.. gives me 33.3% which is more accurate than 33%
$v1_percent = substr($v1_total/$total*100,0,4);
Thanks! Jon