PDA

View Full Version : display numbers in html with comma separator



anitha2324
May 7th, 2007, 09:06 AM
am doing a displaying some data in asp ( data is retreived from the
oracle database)

the data are displaying as the following

income
152000
5200000
8754631


but i just want to display the above with a comma separator

like the following


income
152,000
5,200,000
8,754,631

how i can do this using html or css

harbingerOTV
May 7th, 2007, 01:42 PM
you cant. you need to use something like asp or javascript to do that.

http://www.jsmadeeasy.com/javascripts/Misc/add_comas_to_numeric_entries/add_comas_to_numeric_entries.htm

heres a small javascript that may be modifiable to accomplish what you need. Look around in the asp forum as well. someone might already have somethign you could use.

anitha2324
May 9th, 2007, 09:48 AM
Thanks Alot For That But I Want To Do It In Either
Html Or Css , I Can Also Retreive It From Oracel With Comma Using To_char Function