I am using EJuiDateTimePicker Extension. In which, I want to set a validation that user can not select less time from the current time if Today’s date is selected. If Current date Time is : “2014-08-06 16:40” and from datetime picker, if 6th August date is selected at that time date time picker should not allow user to select the time less than current time i.e. 16:40. If Date is change to any future dat at that time it should allow to select any time.

I have put a same validation in this control for date using "minDate". So controller will not allow to select a date which is less than current date.

Is there any other options available like "minDate" in EJuiDateTimePicker? If no then what is the other way to restrict user not to select time which is less than current time for specific today date??

Thanks in Advance!!!:)

The extensions is based on timepicker addon, see this for the options: http://trentrichardson.com/examples/timepicker/

It has an option minDate which takes an js DateTime object, try this:

"options"=> array(

  "minDate" => "js:new Date(2010, 11, 20, 8, 30)",


Thanks a lot!!!

It works fine… :mellow:

Again one problem :

It takes client side time and server time is different then js time. So is there any way to pass server side time using php or mysql in "minDate" option??


This wiki shows how to get dates and times from the client and server in the same format and in the same timezone.

It also shows what date/time formats to use during validation.