Error in number formatting in case if thousands separator not specified

0 views
Skip to first unread message

Alexander Obuhovich

unread,
Dec 23, 2009, 10:47:08 AM12/23/09
to In-Portal Bugs
It appears, that number_format function seems to use "," as thousands separator even in case if thousands separator is not entered in language properties. By inspecting closely I've discovered, that ThousandsSep field in Language table has NULL value in case if empty value is entered in language properties. When NULL is given to number_format function, then is works as "," instead.

To fix this problem I propose to force type convert (to string) both decimal and thousands separator before passing them to number_format function.

Imported from wiki, originally reported by Grician.
Task: http://tracker.in-portal.org/view.php?id=496  (0000496: Error in number formatting in case if thousands separator not specified).

--
Best Regards,

http://www.in-portal.org
http://www.alex-time.com
thousands_separator_problem.patch
Reply all
Reply to author
Forward
0 new messages