#33917 [Opn->Csd]: number_format incorrect work when use "long" th. separator

From: Date: Fri, 29 Jul 2005 13:00:24 +0000
Subject: #33917 [Opn->Csd]: number_format incorrect work when use "long" th. separator
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-82657@lists.php.net to get a copy of this message
ID: 33917 Updated by: sniper@php.net Reported By: shagren at ua dot fm -Status: Open +Status: Closed Bug Type: Strings related Operating System: Win2k/Linux PHP Version: 5.1.0b3 New Comment: This bug has been fixed in CVS. Snapshots of the sources are packaged every three hours; this change will be in the next snapshot. You can grab the snapshot at http://snaps.php.net/. Thank you for the report, and for helping us make PHP better. Previous Comments: ------------------------------------------------------------------------ [2005-07-29 14:33:25] shagren at ua dot fm Description: ------------ In documentation i can read : Only the first character of thousands_sep is used. For example, if you use foo as thousands_sep on the number 1000, number_format() will return 1f000. But in my example when i use "Long" parameter it ignored and some default value used. I test it on versions 4.3.6, 5.1.0b3 Reproduce code: --------------- <?php echo number_format(123456789,0, '.', '--'); ?> Expected result: ---------------- 123-456-789 Actual result: -------------- 123,456,789 ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=33917&edit=1

« previous php.bugs (#82657) next »