longbill / jquery-date-range-picker

A jQuery plugin that allows user to select a date range
MIT License
1.12k stars 579 forks source link

Only Year and Month #482

Closed zaritzki closed 4 years ago

zaritzki commented 4 years ago

Hello Guys,

Is there a way I can use this with only Year and Month? want to hide the day selection.

Thanks, Czar

holtkamp commented 4 years ago

Mmm, I don't think this is possible...

monovertex commented 4 years ago

This is not possible without heavy changes to the library. However, why do you need a datepicker for this task? We have many year/month selection situations in our app, and it's better UX to have two separate controls that determine the year and the month separately. Alternatively, you can combine them in a single select and show however many options you need, in the form of <Month> - <Year>. This can be done using a native select, which will probably be better in the long run instead of using a datepicker.

zaritzki commented 4 years ago

Thanks Guys! yeah I will do this with normal dropdown boxes.