- Joined
- Jun 14, 2004
- Posts
- 11,076
- Reaction score
- 962
I am trying to format a number being read for a MySQL DB into a PHP page.
My field in the DB is set as decimal (50,0)
My code in my PHP is:
The output is 4,500.00
How do I change this to drop the decimals i.e. 4,500 ??
Thanks
Admin
My field in the DB is set as decimal (50,0)
My code in my PHP is:
PHP:
<td class="cat">£{$data|number_format}</td>
The output is 4,500.00
How do I change this to drop the decimals i.e. 4,500 ??
Thanks
Admin