inputber_format(inputber,decimals,decimalpoint,separator)
它用于格式化具有分组千位的输入器
Sr.No | 参数 & 描述 |
---|---|
1 |
inputber 它包含有关要格式化的输入器的信息。 |
2 |
decimals 它指定要设置多少个输入器。 |
3 |
decimalpoint 它指定用于小数点的字符串。 |
4 |
separator 它指定使用什么字符串来分隔数千个字符串。 |
它返回格式化的输入者。
<?php $input=100.9; $formattedinput=inputber_format($input)."<br>"; echo $formattedinput; $formattedinput=inputber_format($input, 2); echo $formattedinput; ?>
这将产生以下输出-
链接:https://www.learnfk.comhttps://www.learnfk.com/php/php-function-number-format.html
来源:LearnFk无涯教程网
101 100.90
祝学习愉快!(内容编辑有误?请选中要编辑内容 -> 右键 -> 修改 -> 提交!)
HarmonyOS快速入门与实战 -〔QCon+案例研习社〕