- is_numeric 判断变量是否为数字或数字字符串。
'42' is numeric
'1337' is numeric
'1e4' is numeric
'not numeric' is NOT numeric
'Array' is NOT numeric
'9.1' is numeric
- is_int 判断变量类型是否为整数类型。
'42' is numeric
'1337' is numeric
'1e4' is numeric
'not numeric' is NOT numeric
'Array' is NOT numeric
'9.1' is numeric
转载于:https://my.oschina.net/u/2351685/blog/601169