I’ve found a very easy to use datepicker called jquery datepicker. But the problem is when I want to use it for birth date. For example: my birth year is 1986 and the current year is 2013, then I need to click left arrow many times to decrease the months until I find 1986. It will be more troublesome if my birth year is 1960 or below.
Does anybody know any datepicker plugin that suitable for this? Perhaps a datepicker which year or month can be selected from dropbox or something?
In short: you may do that bythe Restricting Datepicker section in the demo page.
If you look down the demo page a bit, you’ll see a “Restricting Datepicker” section. Use the dropdown to specify the “
Year dropdown shows last 20 years” demo , and hit view source:You’ll want to do the same (obviously changing
-20to-100or something).Option # 2: is using the
changeMonthandchangeYearoptions of the api.Try using ‘yy’ for the current year like:
for more information view http://api.jqueryui.com/datepicker/#option-yearRange