Current Location: Home> Function Categories> doubleval

doubleval

alias for floatval
Name:doubleval
Category:Variable processing
Programming Language:php
One-line Description:Alias ​​for floatval().

Definition and usage

doubleval() function returns the floating point value of the variable.

This function is an alias for floatval() .

Example

Returns floating point values ​​of different variables:

 <?php
$a = "1234.56789" ;
echo doubleval ( $a ) . "<br>" ;

$b = "1234.56789Hello" ;
echo doubleval ( $b ) . "<br>" ;

$c = "Hello1234.56789" ;
echo doubleval ( $c ) . "<br>" ;
?>

Try it yourself

grammar

 doubleval ( variable ) ;
parameter describe
variable Required. Specifies the variable to check. Must be a scalar type.
Similar Functions
Popular Articles