【发布时间】:2014-12-04 07:52:49
【问题描述】:
我在搜索中找到的只是一个编程解决方案。 我知道我们可以为英文商店修改 /lib/Zend/Locale/Data/en.xml。 en.xml 中有这部分:
<currencyFormats>
<currencyFormatLength>
<currencyFormat>
<pattern>#,##0.00 ¤</pattern>
</currencyFormat>
</currencyFormatLength>
</currencyFormats>
价格以这种格式显示:1,321.54 现在要从价格中删除小数部分,我认为我唯一要做的就是将 en.xml 更改为如下所示:
<currencyFormats>
<currencyFormatLength>
<currencyFormat>
<pattern>#,##0 ¤</pattern>
</currencyFormat>
</currencyFormatLength>
</currencyFormats>
问题是在此更改后价格显示为所需的(1,132 格式),但没有货币符号 ($)。 我在这里缺少什么? 提前致谢。
更新 我还在尝试,当 pattern 节点更改为以下
<pattern>¤ #,##0</pattern>
价格带有货币符号($ 1,132)但不在所需位置O_O,要求货币符号在右侧没有左侧:( SO..
【问题讨论】:
-
尝试使用这个扩展。 magentocommerce.com/magento-connect/price-rounding.html一般多币种交易时使用。
-
感谢您的回复,我不会使用编程解决方案,解决方案在en.xml中但无法弄清楚如何