Hi!
I'm a bit puzzled... I have a string variable ($test) that holds a value of lets say "1.8", I run this through round and..??
$result = round($test, 1);
Now $result is == 1
If I set the var to "1,8" $result == 1.8
Why?
Hey i tried you code and i got 1.8 back
If you need to cast a variable use this method
$new_res =(float)$result;
You can use this with all types
Mark www.hdwt.com
Yes I know!?? That is what puzzles me, that before this I did get the right result, it worked with a dot (.) but then all of a sudden it requires a comma (,)?
Has this something to do with the locale setting? setlocale etc... ??