JavaScript Reference/Javascript Methods/floor
"floor()" Example
<html>
<body>
<button onclick="alert(Math.floor(1.1));">FLOOR</button>
</body>
</html>
"floor()" is applied to
+----------------+--------------------------------------------------------------+
| Applied_To |Math |
+----------------+--------------------------------------------------------------+
"floor()" Syntax, Parameters and Note
Note:
Rounds the number down to the nearest integer.
Syntax:
Math.floor(param1)
Parameters:
param1 Required; the number to convert.