Fra*_*ank 1 php number-formatting
我在php中使用一个很小的代码时遇到了麻烦:
$price = 135;
$price_sale = number_format($price * 0.75,2,',','');
//*returns 101,25 *//
$count_products = 3;
$new_price = number_format($price_sale * $count_products,2,',','');
//* returns 303,00 and not 303,75 *//
Run Code Online (Sandbox Code Playgroud)
我该如何解决这个问题?
问候,
坦率
| 归档时间: |
|
| 查看次数: |
2776 次 |
| 最近记录: |