Topic: Datepicker disables incorrect month
Danny Pringle
pro
asked 5 years ago
The following code disables JUNE in stead of MAY? It happens for any month of the year. What do I need to change to get the correct month disabled?
` // Data Picker Initialization
$('.datepicker').pickadate({
min: true,
disable: [
1,7,
[2017,5,15],
[2017,5,16],
[2017,5,22]
]
})
Add comment
Danny Pringle
pro
answered 5 years ago
Hi
Found my fault thanks - new to Java: months in a JavaScript Date object are zero-indexed.
Regards
FREE CONSULTATION
Hire our experts to build a dedicated project. We'll analyze your business requirements, for free.
Status
Specification of the issue
- User: Pro
- Premium support: No
- Technology: General Bootstrap questions
- MDB Version: -
- Device: -
- Browser: -
- OS: -
- Provided sample code: No
- Provided link: No
Tags