smarty math返回逗号而不是point

时间:2015-06-25 17:51:12

标签: decimalformat smarty3

在Smarty中执行此操作

{math equation=1.1+0.7 format="%.2f"}

我得到一个逗号分隔的小数为1,80的结果

不知道如何获得1.80的价值。

Thnx。

1 个答案:

答案 0 :(得分:2)

The only solution i have found is to replace the comma with a poin.

math|replace:",":"."

Hope it helps someone.

相关问题