DrumAt5280
Technical User
I have an input date field along side a pop-up calendar so the user can either pick from the pop-up calendar or type the date in too.
When a user types in a date that can not be converted to a date that CF understands it throws an error - which makes sense.
Is there a way i can check for a valid date, and if it is not a valid date format can i set a valid one for them?
I was thinking of something like this even though there is no such tag "ISDATE":
<cfif ISDATE('FORM.date')>
<CFSET Date= #FORM.date#>
<cfelse>
<cfset Date = now()>
</cfif>
Thanks!
When a user types in a date that can not be converted to a date that CF understands it throws an error - which makes sense.
Is there a way i can check for a valid date, and if it is not a valid date format can i set a valid one for them?
I was thinking of something like this even though there is no such tag "ISDATE":
<cfif ISDATE('FORM.date')>
<CFSET Date= #FORM.date#>
<cfelse>
<cfset Date = now()>
</cfif>
Thanks!