Here i have “From Date” and “To Date” with submit button. And i’m using telerik radate control for this project. So, I couldn’t add that telerik control.
Here Everything is fine for my requirement and one enhancement is there.
http://jsfiddle.net/ssthil/4tyJ4/
Additional Info :
The “From Date” will not be earlier than 13 months back compare with “To Date”.
How to add the validation for this? looking for your help.
You can set the month to a date in the past and compare with that:
Fixing the day as suggested by @mplungjan:
Updated fiddle: Use a clone of
endDateinstead oftodayto initback, then compare withstartDate: