Page is a not externally linkable
- Code, Content, and Presentation
-- PHP Server Side Scripting
---- send price such as 1000.50 using a form


helenp - 9:59 pm on Jan 16, 2013 (gmt 0)


I think I should use one input and then format the price correctly.
I ever used filters or regex, and I think this is the filters I need to change 1.001.50 to 1000.50 however it does not work,
what am I doing wrong?
$var = filter_var($price,FILTER_SANITIZE_NUMBER_FLOAT, FILTER_FLAG_ALLOW_FRACTION);
echo $var;


Thread source:: http://www.webmasterworld.com/php/4536595.htm
Brought to you by WebmasterWorld: http://www.webmasterworld.com