Input DatetimeLocal stepDown() Method - Javascript DOM HTML Element

Javascript examples for DOM HTML Element:Input Datetime Local


The stepDown() method decrements the MINUTES of the local datetime field by a specified number.

Parameter Values

Parameter Description
numberRequired. the amount of minutes the datetime field should decrease. If omitted, the minutes are decremented by "1"

Return Value:

No return value

The following code shows how to Decrement the value of a datetime field by 10 minutes:

Demo Code

ResultView the demo in separate window

<!DOCTYPE html>
Date: <input type="datetime-local" id="myLocalDate" value="2014-11-16T15:00:33">

<button onclick="myFunction()">Test</button>

function myFunction() {/*from  w ww . ja v a2s. c o m*/


Related Tutorials