0

I am trying to open a datepicker that only allows months to be chosen, so I am trying to use the minViewMode option but it is not working. It allows me to view the days of each month.

$("#datepicker").datepicker({
        format: "mm-yyyy",
        minViewMode: 1,
        changeMonth: true,
        changeYear: true
});

This produces the below datepicker:

enter image description here

I am aiming for something similar to the following:

enter image description here

Gary
  • 129
  • 4
  • 14
  • You can use [bootstrap-datepicker](http://bootstrap-datepicker.readthedocs.io/en/latest/index.html). If you want to use jQuery UI datepicker to only select years and month see [here](https://stackoverflow.com/q/2208480/4131048). – VincenzoC Jan 05 '18 at 14:32
  • good solution to this duplicate question https://stackoverflow.com/questions/2208480/jquery-ui-datepicker-to-show-month-year-only?noredirect=1&lq=1 – Apps-n-Add-Ons Jan 05 '18 at 14:35

0 Answers0