Page 1 of 1

conver string to float

Posted: Sun Sep 26, 2004 10:05 am
by pelegk2
i have a float nu,ber like this :
1680.03
when i try to conver it : (float)1680.03
i get the value 1 !!!
why is that?what can i do?
thnaks i nadvance
peleg

Posted: Sun Sep 26, 2004 10:09 am
by John Cartwright
for the sake of trial, try (int)# and then (float)#

Just reading on php.net because I generally don't know much about these :P

Posted: Sun Sep 26, 2004 10:14 am
by feyd
[php_man]floatval[/php_man]