![Antiguo](http://static.forosdelweb.com/fdwtheme/images/statusicon/post_old.gif)
23/08/2004, 00:35
|
| | Fecha de Ingreso: enero-2004
Mensajes: 235
Antigüedad: 21 años, 1 mes Puntos: 0 | |
Cita:
Iniciado por jpinedo Una variable que contiene un string es un "string" y no un "float" (o double).
Tampoco es un "numeric", pero la función is_numeric() es capaz de evaluar si ese string contiene un número hecho cadena.
Según el manual, es la única función capaz de reconocerlo. Extraido del manual: Cita: is_float
(PHP 3, PHP 4 , PHP 5)
is_float -- Finds whether a variable is a float
Description
bool is_float ( mixed var)
Returns TRUE if var is a float, FALSE otherwise.
Note: To test if a variable is a number or a numeric string (such as form input, which is always a string), you must use is_numeric().
See also is_bool(), is_int(), is_integer(), is_numeric(), is_string(), is_array(), and is_object(), Un "mixed var" que seria? Yo entiendo qualquier tipo de variable. |