If the function floatval does not work you can try to make this :
$string = "2968789218";
$float = $string * 1.0;
echo $float;
But for me all the previous answer worked ( try it in http://writecodeonline.com/php/ ) Maybe the problem is on your server ?