How set float precision for 'echo' in php more 12 digits without number_format()?
PHP code: $val1 = 32; $val2 = 0.00012207031255; $res = $val1 - $val2; echo "echo: ".$res."n"; echo "json: ".json_encode($res)."n"; echo "form: ".number_format($res, 14); Output: echo: 31.999877929687 json: 31.99987792968745 form: 31.99987792968745 How to display 14 decimal places in echo without number_format()…