RE: [PHP] Changing numbers

2003-07-21 Thread Roger B.A Klorese
> From: Brad Pauly [mailto:[EMAIL PROTECTED] > Sent: Monday, July 21, 2003 2:45 PM > To: Roger B.A Klorese > Cc: 'justin gruenberg'; 'Curt Zirzow'; 'PHP-General' > Subject: Re: [PHP] Changing numbers > > > I am not sure what he is aft

Re: [PHP] Changing numbers

2003-07-21 Thread Brad Pauly
Roger B.A Klorese wrote: * Thus wrote zavaboy ([EMAIL PROTECTED]): I have the following numbers: 12.400 666.75 23 369.2 3.234 How can I make them have at least 2 decimal places? So, they will output: 12.40 666.75 23.00 269.20 3.234 What's so hard about this? He wants two or more *significant*

RE: [PHP] Changing numbers

2003-07-21 Thread Roger B.A Klorese
> From: justin gruenberg [mailto:[EMAIL PROTECTED] > Subject: Re: [PHP] Changing numbers > > > Curt Zirzow wrote: > > >* Thus wrote zavaboy ([EMAIL PROTECTED]): > > > > > >>I have the following numbers: > >> > >>12.400 > >

Re: [PHP] Changing numbers

2003-07-21 Thread justin gruenberg
Curt Zirzow wrote: * Thus wrote zavaboy ([EMAIL PROTECTED]): I have the following numbers: 12.400 666.75 23 369.2 3.234 How can I make them have at least 2 decimal places? So, they will output: 12.40 666.75 23.00 269.20 3.234 Thanks in advance! What I dont understand is that your examples are

Re: [PHP] Changing numbers

2003-07-21 Thread Curt Zirzow
* Thus wrote zavaboy ([EMAIL PROTECTED]): > I have the following numbers: > > 12.400 > 666.75 > 23 > 369.2 > 3.234 > > How can I make them have at least 2 decimal places? > So, they will output: > > 12.40 > 666.75 > 23.00 > 269.20 > 3.234 > > Thanks in advance! http://php.net/number_format or

Re: [PHP] Changing numbers

2003-07-21 Thread John Nichel
bob parker wrote: On Tue, 22 Jul 2003 04:03, zavaboy wrote: *Sigh*, lets say I have: 2.65 3.3 5.2670 12.030 I would like it at least 2 decimal places.. So, 5.2670 would be 5.267 not 5.27: 5.267 is 3 decimal places - count them He said "at least 2 decimal places", not "exactally two decimal pla

Re: [PHP] Changing numbers

2003-07-21 Thread bob parker
On Tue, 22 Jul 2003 04:03, zavaboy wrote: > *Sigh*, lets say I have: > > 2.65 > 3.3 > 5.2670 > 12.030 > > I would like it at least 2 decimal places.. So, 5.2670 would be 5.267 not > 5.27: > 5.267 is 3 decimal places - count them -- PHP General Mailing List (http://www.php.net/) To unsubscribe, v

Re: [PHP] Changing numbers

2003-07-21 Thread John Nichel
zavaboy wrote: *Sigh*, lets say I have: 2.65 3.3 5.2670 12.030 I would like it at least 2 decimal places.. So, 5.2670 would be 5.267 not 5.27: 2.65 3.30 5.267 12.03 "James Rodenkirch" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] try rounding it first http://www.php.net/manual/en/fu

RE: [PHP] Changing numbers

2003-07-21 Thread Jay Blanchard
[snip] I would like it at least 2 decimal places.. So, 5.2670 would be 5.267 not 5.27: [/snip] RTFM for formatted string http://us3.php.net/sprintf or http://us3.php.net/printf HTH -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Changing numbers

2003-07-21 Thread zavaboy
*Sigh*, lets say I have: 2.65 3.3 5.2670 12.030 I would like it at least 2 decimal places.. So, 5.2670 would be 5.267 not 5.27: 2.65 3.30 5.267 12.03 "James Rodenkirch" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > try rounding it first > > http://www.php.net/manual/en/function.

Re: [PHP] Changing numbers

2003-07-21 Thread James Rodenkirch
try rounding it first http://www.php.net/manual/en/function.round.php Zavaboy wrote: What about if I had 2.856 that function will make it 2.86. "Jay Blanchard" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] [snip] How can I make them have at least 2 decimal places? [/snip] RTFM at

Re: [PHP] Changing numbers

2003-07-21 Thread zavaboy
What about if I had 2.856 that function will make it 2.86. "Jay Blanchard" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] [snip] How can I make them have at least 2 decimal places? [/snip] RTFM at http://www.php.net/number_format HTH! -- PHP General Mailing List (http://www.php

RE: [PHP] Changing numbers

2003-07-21 Thread Jay Blanchard
[snip] How can I make them have at least 2 decimal places? [/snip] RTFM at http://www.php.net/number_format HTH! -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Changing numbers

2003-07-21 Thread zavaboy
I have the following numbers: 12.400 666.75 23 369.2 3.234 How can I make them have at least 2 decimal places? So, they will output: 12.40 666.75 23.00 269.20 3.234 Thanks in advance! -- - Zavaboy [EMAIL PROTECTED] www.zavaboy.com -- PHP General Mailing List (http://www.php.net/) To unsu