This shows you the differences between two versions of the page.
Both sides previous revision Previous revision Next revision | Previous revision | ||
uphp:functions:is_numeric [2017/04/04 14:10] jeff |
uphp:functions:is_numeric [2021/09/13 05:57] (current) |
||
---|---|---|---|
Line 3: | Line 3: | ||
< | < | ||
- | Return 1 if the value is numeric (< | + | < |
====Description==== | ====Description==== | ||
- | <well size=" | + | <well size=" |
- | <span style=" | + | <span style=" |
- | < | + | <span style=" |
<span style=" | <span style=" | ||
<span style=" | <span style=" | ||
Line 15: | Line 15: | ||
</ | </ | ||
- | Check if a value is numeric | + | Check to see if a value is numeric |
====Parameter==== | ====Parameter==== | ||
Line 21: | Line 21: | ||
< | < | ||
- | ====Return | + | ====Return |
- | 1 (true) if numeric, 0 (false) if not numeric (arrays always return 0) | + | < |
====Examples==== | ====Examples==== | ||
Line 40: | Line 40: | ||
</ | </ | ||
- | **Set up an array of different types of values. Then iterate through the array and output | + | ===Set up an array of different types of values, iterate through the array, output type, value and whether is_numeric() returns true or false=== |
<code php> | <code php> | ||
Line 93: | Line 93: | ||
====See Also==== | ====See Also==== | ||
- | [[is_int()]] - Return 1 if the variable is an < | + | [[is_int()]] - Check if a variable is an < |
- | [[is_float()]] - Return 1 if the variable is a < | + | [[is_float()]] - Check if a variable is a < |
- | [[is_string()]] - Return 1 if the variable is a < | + | [[is_string()]] - Check if a variable is a < |
- | [[is_array()]] - Return 1 if the variable is an < | + | [[is_array()]] - Check if a variable is an < |
- | [[isset()]] - Return 1 if the variable exists | + | [[isset()]] - Check if a variable exists |
[[uphp: | [[uphp: |