I have three listboxes for a date - day,month and year.
The day listbox has values 1-31
The Month listbox has values 1-12
The Year listbox has values 2005-2010
I concatonate these values and pass them to a database, so I have control over the format.
This works fine until you select 31/06/2005 (an invalid date because June only has 30 days)
I need a simple javascript test to tell me whether a date is valid or invalid.
I have a rudementary knoweledge of javascript and could program a solution but I would like to avoid a lengthy coding process if there is a simple answer.
I have found several lengthy date validation routines on the web, but they mainly deal with dates that are of an indeterminate format.
The day listbox has values 1-31
The Month listbox has values 1-12
The Year listbox has values 2005-2010
I concatonate these values and pass them to a database, so I have control over the format.
This works fine until you select 31/06/2005 (an invalid date because June only has 30 days)
I need a simple javascript test to tell me whether a date is valid or invalid.
I have a rudementary knoweledge of javascript and could program a solution but I would like to avoid a lengthy coding process if there is a simple answer.
I have found several lengthy date validation routines on the web, but they mainly deal with dates that are of an indeterminate format.