num
This function converts a variable to a plain numeral.
Indirect parameter passing is disabled
1
No. | Type | Description |
---|---|---|
1 input |
valid types | Value Strings containing numbers (no text before numbers) are converted properly. Scientific notation is supported. |
Type | Description |
---|---|
numeral | number Contains resulting number. No string context of the number is preserved or included. |
echo( num( '1.2E+03' ) );
echo( num( true ) );
echo( num( 0123 ) );
echo( num( date ( "05. Nov 2019 12:00" ) ) );
1200
1
123
20191105.5
string conversion functions
date
pure date
date time
clean num
smart num