is_real

(PHP 4, PHP 5, PHP 7)

is_realis_float() 的别名

描述

此函数是 is_float() 的别名函数。

User Contributed Notes

charlescbe16 at gmail dot com 24-Jul-2010 09:53
is_float — Finds whether a variable is a floatDescriptionbool is_float ( mixed var )

Finds whether the given variable is a float.

example:
<?php
$float
=50.97;
if(
is_float($float))
{
    echo
$float."is a float";
}
else
{
    echo
$float. "is not a float";
}
?>

output:
50.97 is a float