Input Date stepDown() 方法
实例
例子 1
将日期字段的值减少 5 天:
document.getElementById("myDate").stepDown(5);
例子 2
将天数减 1(默认):
document.getElementById("myDate").stepDown();
语法
inputdateObject.stepDown()number)
Parameter Value
Parameter | Description |
---|---|
number |
Required. Specifies the number of days to be reduced from the date field. If omitted, the number of days is reduced by "1". |
Technical Details
Return value:
No return value.
Browser Support
Numbers in the table indicate the first browser version to fully support this property.
Chrome | Edge | Firefox | Safari | Opera |
---|---|---|---|---|
Chrome | Edge | Firefox | Safari | Opera |
Support | 12.0 | 17.0 | Support | Support |