Number Normalization for Zend Framework 2

寵の児 提交于 2019-12-13 06:36:05

问题


I'm trying to normalize a number from a form, which will/could be in the local number format. e.g.

Locale:en-US
1,234.56 -> 1234.56

Locale:nl-NL
1.234,56 -> 1234.56

Is there an equivalent in ZF2 to the ZF1 Zend_Locale_Format::getNumber?

Thanks in advance

Aborgrove.


回答1:


You mean something like the numberFormat Filter?



来源:https://stackoverflow.com/questions/17595260/number-normalization-for-zend-framework-2

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!