Results 1 to 8 of 8
Nov 18, 2011, 04:53 #1
- Join Date
- Nov 2011
- 0 Post(s)
- 0 Thread(s)
I want to validate when date and time selected is past current date and time
I have two readonly textboxes, one textbox is linked with the jquery datepicker and the other textbox is linked with the timepicker jquery. Now the great thing about the jquery datepicker is that I can range my dates so that the user cannot select any dates before the current date. But the Jquery timepicker cannot be ranged so the time is before the current time.
Because of this there is a possbile chance that the user can select the current date but a time before the current time. Obviously this means the time chosen has passed the current time of the current day which I don't want happening. So a validation is needed where if date textbox and time textbox is past the current date and time, then a message is displayed stating "The Date and Time you have selected is before the Current Date and Time" else if time and date together is past current date and time then display "".
How can I do this. Below is my best attempt at it but I couldn't get it to work.