Categories
php how to display zeros after dot?
How can I specify a template for a number and cast it to this form? for example 2 dots after the comma: 12.23 12.20 12.00 i.e. the number of decimal places is unchanged
Answer the question
In order to leave comments, you need to log in
number_format($number, 2, '.',' ');
printf("%01.2f", 100.1);
Didn't find what you were looking for?
Ask a Question
731 491 924 answers to any question