Right Will.. I do that too sometimes. I got in kinda late on this one, but
couldn't you just use isDate() on the server side backend and javascript to
validate the front end?
JavaScript would be a regex which would be something like this.
<script>
function checkform() {
if(!document.forms[0].elements[0].value.length){
alert("Please fill in the date!");
document.forms[0].elements[0].focus();
return false;
}
var regex = /^\d{1,2}\/\d{1,2}\/\d{4}$/;
if(!regex.test(document.forms[0].elements[0].value)) {
alert(document.forms[0].elements[0].value +
" is NOT a valid date:" + " " + "THIS FORMAT PLEASE XX/XX/XXXX");
document.forms[0].elements[0].focus();
return false;
}
}
</script>
Warmest Regards,
Phillip B. Holmes
http://phillipholmes.com
-----Original Message-----
From: Will Tomlinson [mailto:[EMAIL PROTECTED]
Sent: Saturday, June 17, 2006 11:03 AM
To: CF-Talk
Subject: Re: Validating a date
>Can you do 3 <select> inputs (month / date / year)?
>
>I've found that to be one of the easier ways to ensure a date in a valid
format.
uhh... duhhhhh... Thanks charlie. That sounds like a good plan. :)
Will
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Message: http://www.houseoffusion.com/lists.cfm/link=i:4:243949
Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4
Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4
Unsubscribe:
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4
Donations & Support: http://www.houseoffusion.com/tiny.cfm/54