I am trying to round down numbers using PHP.
I have managed to do this if the value has a decimal place, using this method below.
$val = floor($val * 2) / 2;
echo 'hello'. $val;
If the value I am trying to round down doesn't have a decimal place and the above code is not working.
The values I am trying to round down.
32456 => 32000
4567 => 4000
38999 => 38000