You should be precise...
What is 1,235.23 as var_dump ?

Are both values strings?
And what is your system's locale?

What do you set within the registry?
Are you "hardcoding" en_IN or are you relying on the system/browser/autosettings?

Greetings
Thomas Weidner, I18N Team Leader, Zend Framework
http://www.thomasweidner.com

----- Original Message ----- From: "nisanth" <nisanthkumar...@gmail.com>
To: <fw-general@lists.zend.com>
Sent: Tuesday, March 23, 2010 8:24 AM
Subject: [fw-general] How to convert different local float format to standard float format, using zend?





my local is 'en_IN' (ie Zend_Registry::get('Zend_Locale'))

I have to convert the local value to standard float number format

for example

1,235.23 => 1235.23

3.23 => 3.23

I have used the following code

Zend_Locale_Format::getFloat($value, array('locale' =>
Zend_Registry::get('Zend_Locale')));

it working fine for 1,235.23, and i get the answer 1235.23.

But when i give 3.23 , i get the error on this code




And the error shown as

'No localized value in 3.23 found', This issue is happening in the browser
opera, when we set the language is English(IN)(en-IN)
--
View this message in context: http://n4.nabble.com/How-to-convert-different-local-float-format-to-standard-float-format-using-zend-tp1678730p1678730.html Sent from the Zend Framework mailing list archive at Nabble.com.

Reply via email to