Hello, [!

Thursday, February 01, 2001, 06:33:53, you wrote:

r> Is there a simple way to format a variable into an appropriate financial 
r> string...
r> I'd like all of the above to format as $XXX.XX

   try to use
   
   $value = 5.0;
   $sval = sprintf("$%003.2f",$value);

   $sval will contain formatted value.


Best regards!
Andrew Golovin
PGP Fingertip 24FD A0CD 667C 1FC7 C2F7  A2EA 9742 D484 FD3C 598D
http://exper.ural.ru/ 



-- 
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]

Reply via email to