smalot / bootstrap-datetimepicker

Both Date and Time picker widget based on twitter bootstrap (supports Bootstrap v2 and v3)
http://www.malot.fr/bootstrap-datetimepicker/
Apache License 2.0
3.49k stars 1.65k forks source link

How to know if user click on 'prev' or 'next' button for previous/ next month #725

Open tenznhok opened 6 years ago

tenznhok commented 6 years ago

Hi, Is there a way to know if user click on prev/next button in the calendar? I know the on('changeDate') is detected if user change the selected date. But if user click on the << or >> in the calendar, how do I know it, and also how to detect what month is it showing.

 $("#dateTimePickerInput").datepicker({
        endDate: new Date,
        todayHighlight: true}
    ).on('changeDate', function (e) {});