php float 2 decimais
$foo = "105";
echo number_format((float)$foo, 2, '.', '');
php float 2 decimais
$foo = "105";
echo number_format((float)$foo, 2, '.', '');
format php currency
<?php
// beware: number_format also rounds
$number = 1234.56;
// english notation (default)
$english_format_number = number_format($number);
// 1,235
// French notation
$nombre_format_francais = number_format($number, 2, ',', ' ');
// 1 234,56
$number = 1234.5678;
// english notation without thousands separator
$english_format_number = number_format($number, 2, '.', '');
// 1234.57
Copyright © 2021 Codeinu
Forgot your account's password or having trouble logging into your Account? Don't worry, we'll help you to get back your account. Enter your email address and we'll send you a recovery link to reset your password. If you are experiencing problems resetting your password contact us