DateRange for DatePicker
See original GitHub issueI have two datepicker inputs and I want that user selects a date range.
this is the expected behavior:
1- user clicks on the first datepicker input and selects the first day. now the start day must have class
-selectedStart
2- user clicks on second datepicker input to select end day. this time datepicker have to keep the first value from first datepicker as ‘from’ and set new value as ‘to’.
the question is how can I do this for two different datepicker (e.g. keeping selectedStart for second datepicker) and set selected value for each input? a similar implementation is on alibaba hotel datepicker
Issue Analytics
- State:
- Created 4 years ago
- Comments:10 (6 by maintainers)
Top Results From Across the Web
Date Range Picker — JavaScript Date & Time Picker Library
A JavaScript component for choosing date ranges, dates and times. ... Originally created for reports at Improvely, the Date Range Picker can be...
Read more >Date range picker on jquery ui datepicker - Stack Overflow
So I took the original answer and just made a few minor changes: In html, create a hidden input associated with the datepicker....
Read more >Date Range Picker for Bootstrap
The Date Range Picker can be turned into a single date picker widget with only one calendar. In this example, dropdowns to select...
Read more >Markup — bootstrap-datepicker documentation - Read the Docs
Using the input-daterange construct with multiple child inputs will instantiate one picker per input and link them together to allow selecting ranges. <div ......
Read more >Date Range in JavaScript DatePicker control - Syncfusion
DatePicker provides an option to select a date value within a specified range by using the min and max properties. Always the min...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
@thebrodmann thank you for taking care of this issue, highly appreciate that 😊
thanks, @thebrodmann! this is final try on selecting a range from datepicker. at last, I format the input date and show the user only the ‘to’ value. for ‘from’ datepicker I used single date selection and for ‘to’ datepicker I used date range including an object that has ‘from’ and ‘to’ value.