Gets the float value of var.
PHP floatval() function has the following syntax.
float floatval ( mixed $var )
The float value of the given variable. Empty arrays return 0, non-empty arrays return 1.
Get the float value
<?php
$var = '122.34343The';
$float_value_of_var = floatval($var);
echo $float_value_of_var; // 122.34343
?>
The code above generates the following result.