|
number_formatFormat a number with grouped thousands Description
string number_format(
float $num ,int $decimals = 0,stringnull $decimal_separator = ".",stringnull $thousands_separator = ",") Formats a number with grouped thousands and optionally decimal digits using the rounding half up rule. Parameters
Return Values
A formatted version of Changelog
Examples
Example #1 number_format Example For instance, French notation usually use two decimals, comma (',') as decimal separator, and space (' ') as thousand separator. The following example demonstrates various ways to format a number:
See Also
|