摘要:
$format = 'The %2$s contains %1$04d monkeys! %s apples.';echo sprintf($format, 4, 'tree');// output: The tree contains 0004 monkeys! 4 apples.// number_format(数字, 保留小数位数, 小数分割符='.', 千分位分隔符=',');$num = 1234.567;echo number_format($num); // 1,235echo number_format($num, 阅读全文
posted @ 2013-02-27 10:45 PHP-张工 阅读(2892) 评论(0) 推荐(0) 编辑