Solved

datepicker and timepicker validation

Posted on 2010-09-20
4
605 Views
Last Modified: 2012-05-10
Hello experts. Looking for date time validation for datepicker and timepicker I have a from date and from time and a to date and to time. To value cannot be less that from value and if from and to date value is the same then time value must pass validation and have a min time diff of 1 hour.
0
Comment
Question by:ikeyser
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
  • 2
4 Comments
 
LVL 40

Expert Comment

by:gurvinder372
ID: 33722406
you can check this link, they have shown that you can force the validation at the selection of date from datepicker

http://forum.jquery.com/topic/jquery-plugin-validation-date-picker-jquery-ui
http://forum.jquery.com/topic/ui-datepicker-w-validation-plugin-doesnt-get-ride-of-error-message
0
 

Author Comment

by:ikeyser
ID: 33727713
quirvinder -  I don't want the validation to occur until they submit the form.  
0
 
LVL 40

Accepted Solution

by:
gurvinder372 earned 500 total points
ID: 33728412
you can force the validation (of date) on that particular element.
please refer to the first link for the same above.
you can set the date validation on the same
http://docs.jquery.com/Plugins/Validation/Methods/date

Also you need add the custom validation methods
http://stackoverflow.com/questions/833997/end-date-greater-than-start-date-jquery-validation
http://stackoverflow.com/questions/1244738/time-validation-and-comparing-using-javascript-jquery
0
 

Author Closing Comment

by:ikeyser
ID: 33766282
I was looking for a more complete solution.
0

Featured Post

Webinar: Aligning, Automating, Winning

Join Dan Russo, Senior Manager of Operations Intelligence, for an in-depth discussion on how Dealertrack, leading provider of integrated digital solutions for the automotive industry, transformed their DevOps processes to increase collaboration and move with greater velocity.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Link Anchor Not working 9 67
Glitching Slide Show 19 39
CSS Formatting Getting Stripped 1 35
bootstrap form validations! 1 40
I have answered several questions lately that were solved utilizing the power of jQuery's AJAX functions, so I thought I would write an article demonstrating the ease of use. Why should I use jQuery as opposed to regular JavaScript? Now I know…
This article discusses how to implement server side field validation and display customized error messages to the client.
The viewer will learn how to dynamically set the form action using jQuery.
The viewer will learn the basics of jQuery including how to code hide show and toggles. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery…

734 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question