Exit
  • Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
  • 한국 커뮤니티
0

Formatting Numbers

New Here ,
Aug 03, 2006 Aug 03, 2006
Hi!

I know I should know this! I have just started with PHP - I have used ASP in the past. If I bring a field from a recordset and place it on the page, I can use dreamweaver to format it to use commas when it is over 1,000 or decimal points. I can't figure out how to do the same thing in PHP! (using MySQL - field set to float?)

Thanks!
Julie
TOPICS
Server side applications
326
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Aug 03, 2006 Aug 03, 2006
LATEST
tccdover wrote:
> I know I should know this! I have just started with PHP - I have used ASP in
> the past. If I bring a field from a recordset and place it on the page, I can
> use dreamweaver to format it to use commas when it is over 1,000 or decimal
> points.

http://www.php.net/manual/en/function.number-format.php

--
David Powers
Adobe Community Expert
Author, "Foundation PHP for Dreamweaver 8" (friends of ED)
http://foundationphp.com/
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines