If you want to use the datepicker with year selector, you do not need future years. When setting
selectYears: 100
it shows 50 years in the future and 50 years in the past. It would make more sense if you can set an intervall or set negative years like:
selectYears: -100
to show the last 100 years in the dropdown
@domste it think you want to file this as issue in the pickadate repository as this is the behavior of pickadate.js http://amsul.ca/pickadate.js/date/#selectors
you are right, I'm sorry.
I was just working with this.... here's what you do.
$('.datepicker').pickadate({
max: new Date(),
selectMonths: true, // Creates a dropdown to control month
selectYears: 100 // Creates a dropdown for 100 years (up to the max date you set)
});
This stops the date at the current date as the max. Then when you enter the years in 'selectYears' it will only go previous 100 years. (Or what ever number you put in)
At least it worked for me. Hope this helps.
Would be good if max: new Date() was in the docs.
Most helpful comment
Would be good if
max: new Date()was in the docs.