Edit report at https://bugs.php.net/bug.php?id=53735&edit=1
ID: 53735
Comment by: meave390 at gmail dot com
Reported by: mortenskyt at gmail dot com
Summary: NumberFormatter returns NaN when converting float
point
Status: Not a bug
Type: Bug
Package: I18N and L10N related
Operating System: MacOS X 10.6.6
PHP Version: 5.3.5
Block user comment: N
Private report: N
New Comment:
Best article i like to see https://freerobuxtips.com Free
robux any time read this
Previous Comments:
------------------------------------------------------------------------
[2021-10-01 12:23:34] meave390 at gmail dot com
thaks here
------------------------------------------------------------------------
[2016-06-06 19:16:04] ab@php.net
Sorry, but your problem does not imply a bug in PHP itself. For a
list of more appropriate places to ask for help using PHP, please
visit http://www.php.net/support.php as this bug system
is not the
appropriate forum for asking support questions. Due to the volume
of reports we can not explain in detail here why your report is not
a bug. The support channels will be able to provide an explanation
for you.
Thank you for your interest in PHP.
First reported with PHP 5.3, the last comment is about 5.5. ICU version producing the issue stays
however within the same version range. Today PHP 5.5+ with ICU 51.2+ shows no issues. This brings to
the conclusion, that the issue doesn't lay on PHP. Rougly same ICU (or maybe just data) version
range produces the issue. For what matters, I've added ext/intl/tests/bug53735.phpt with all
the snippets from this ticket.
Thanks.
------------------------------------------------------------------------
[2015-10-01 20:04:11] info at netonme dot de
PHP Version 5.5.29-1
ICU version 4.4.1
$fmt = new \NumberFormatter("de_DE", \NumberFormatter::DECIMAL);
$fmt->format(23.25);
Returns NaN
------------------------------------------------------------------------
[2013-03-11 10:52:43] bghome at gmail dot com
I can reproduce this with PHP 5.3.10 on Ubuntu 12.04 64.
It is strange for me, because running from CLI works as expected.
Code to run:
$f = new NumberFormatter('hu_HU', NumberFormatter::PERCENT, '#,##0%');
echo $f->format(0.26) . "\n";
------------------------------------------------------------------------
[2012-05-24 09:59:00] arthur_jambon at prizee dot fr
Get always NaN with NumberFormatter::ORDINAL if the current local is not en_US.
PHP 5.3.3
ICU lib 4.4.1-8
OS Debian Squeeze
------------------------------------------------------------------------
The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
https://bugs.php.net/bug.php?id=53735
--
Edit this bug report at https://bugs.php.net/bug.php?id=53735&edit=1