Stefan
|
| Posted: 05/13/2003, 7:12 AM |
|
Hi,
i have a form with two input fields Start and End, both DateTime, Format: dd.mm.yyyy H:nn (European)
If the user selects via Datepicker a date and submits the form no error ocours. How can i validate that Date and Time ist correct?
Next Question: How can i validate that End is greater than Start
I hope anyone can help me
Lang: PHP, DB: MySQL
Regards
Stefan
|
|
|
 |
Headhunter
|
| Posted: 05/13/2003, 8:19 AM |
|
As far as I know you cannot use the datepicker for DateTime fields, only for Date fields. I could be wrong
|
|
|
 |
TimY
|
| Posted: 05/13/2003, 12:07 PM |
|
http://www.gotocode.com/disc_viewt.asp?mid=20331&
|
|
|
 |
Stefan
|
| Posted: 05/13/2003, 11:56 PM |
|
Thanks for theses Hints, start greater than end works
but has anyone a hint for validating the Date and Time Mask, i tried it with this, European Format the Input has to look like this: dd.mm.yyyy HH:nn
$start_test = $time_test->start->GetValue();
if (!CCValidateDateMask($start_test, array("dd",".","mm",".","yyyy"," ","HH",":","nn")))
{
$time_test->Errors->addError("The Date/Time has not the right Mask!");
}
But this doesnt work.
Regards
Stefan
|
|
|
 |
|