PHP number_format and insert to DB
Posted: Sat May 31, 2014 11:52 pm
I'm retrieving values from MySQL numeric field and want to format with a comma separator for 1000s like this: 21,000
This code below seems to work for display - how do I strip out the commas again before updating and inserting into MySQL DB?
<input type="text" name="Price id="Price value="<?php echo number_format($row_['Price'])); ?>" size="10" />
This code below seems to work for display - how do I strip out the commas again before updating and inserting into MySQL DB?
<input type="text" name="Price id="Price value="<?php echo number_format($row_['Price'])); ?>" size="10" />