Closed (fixed)
Project:
Format Number API
Version:
6.x-1.x-dev
Component:
Code
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
3 Jan 2009 at 15:43 UTC
Updated:
18 Feb 2009 at 17:13 UTC
Jump to comment: Most recent file
Comments
Comment #1
markus_petrux commentedhmm... the problem with multiple byte characters may also happen with the decimal point. For some reason I thought I fixed this, but it seems I forgot to do it. :(
Well, try this code to see how it can also fail with decimal points:
Your change in the way decimal places are counted does not work because it counts trailing zeros to the right of the decimal part. That's why I used preg_replace.
Try this to see what I mean:
Comment #2
markus_petrux commentedCould you please try this one?
Comment #3
markus_petrux commentedOops! Another patch, that also fixes an issue than may happen when the input number in an integer but -1 is passed to display a variable number of decimal places.
Comment #4
xmarket commentedI did a few thousand test during the development of my length converter and I suggest the attached patch.
Comment #5
markus_petrux commentedCommited to CVS, with slight variations. Thanks
Comment #6
markus_petrux commented