Apr 10, 2001 #1 skijohn Technical User Apr 10, 2001 2 US I am attempting to automatically get today's date to be entered into a field in a form as the default value. Can anyone tell me how to do that? Thanks!
I am attempting to automatically get today's date to be entered into a field in a form as the default value. Can anyone tell me how to do that? Thanks!
Apr 10, 2001 #2 AMayer Programmer Sep 23, 2000 82 US <input type="text" name="Date" value="#DateFormat(Now(),"mm/dd/yy"#" size="10"> DateFormat(Now(),"params" works great anytime you need to display the current date. Andrew Upvote 0 Downvote
<input type="text" name="Date" value="#DateFormat(Now(),"mm/dd/yy"#" size="10"> DateFormat(Now(),"params" works great anytime you need to display the current date. Andrew
Apr 26, 2001 #3 Guest_imported New member Jan 1, 1970 0 An other way to do it is the use of the CFPARAM. Just do like this : <cfparam name="Yourdate" default="#now()#"> and after : <input type="text" name="inputname" value="#variables.yourdate#"> you can also apply a dateformat on the variable ! Upvote 0 Downvote
An other way to do it is the use of the CFPARAM. Just do like this : <cfparam name="Yourdate" default="#now()#"> and after : <input type="text" name="inputname" value="#variables.yourdate#"> you can also apply a dateformat on the variable !