At 11:22 9/5/2001 -0700, Gerry wrote: >Could you suggest a function for displaying decimal zeros. > >For example I have this: >$num = "2.00"; >$num2 = "3.00"; >$result = $num + $num2; >echo "$result"; > >I get "5" but not "5.00" try $result = (float)$num + (float)$num2; -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
- [PHP] Working with numbers Jennifer
- Re: [PHP] Working with numbers Christian Reiniger
- Re: [PHP] Working with numbers Jennifer
- Re: [PHP] Working with numbers Oliver Heinisch
- Re: [PHP] Working with numbers Gyozo Papp
- Re: [PHP] Working with numbers Gyozo Papp
- [PHP] Working with numbers Gerry
- Re: [PHP] Working with numbers Reuben D Budiardja
- Christian Dechery