Input Time stepUp() Method

Definition and Usage

stepUp() The method increases the value of the time field by the specified number.

This method only affects minutes (not hours, seconds, or milliseconds).

Tip:To decrease the value, please use stepDown() Method.

Instance

Example 1

Increase the value of the time field by 10 minutes:

document.getElementById("myTime").stepUp(10);

Try it yourself

Example 2

Increase the minutes by 1 (default):

document.getElementById("myTime").stepUp();

Try it yourself

Grammar

timeObject.stepUp(number)

Parameter Value

Parameter Description
number

Required. Specifies the number of minutes to be added to the time field.

If omitted, the minutes are increased by "1".

Technical Details

Return value:

No return value.

Browser Support

The numbers in the table indicate the first browser version that fully supports this property.

Chrome Edge Firefox Safari Opera
Chrome Edge Firefox Safari Opera
Supported 12.0 Not Supported Supported Supported