View Full Version : FrontPage 2003 Form Question...

03-20-2006, 01:32 AM
Hello Everyone!

New to this forum. VERY NICE!

I have a form that currently requires the user to manually input the current date. The date that is input [CurrentDate] by the user is then tied to a verification field [CurrentDate] on the "output page", which is actually just an introduction letter to our potential customer(s).

I am looking for a script that will automate the user date function so that it automatically appears when the user begin completing the form fields. The only real stipulation is that this script must be adjustable so that the date appears in a long format (Month Day, Year). All of the scripts I have seen thus far only allow formats like MM/DD/YYYY. This doesn't look very professional on a letter that is given to the customer.

Thank you for any assistance in advance! Looking forward to learning many things on this forum.

03-20-2006, 03:57 AM
Put this in the body of a page, just as a test of the toLocaleDateString() method:

<br><script type="text/javascript">
var d=new Date();

If you like it, work it into your script.

One thing to keep in mind is, and this could be a good thing for you, if you think about it, toLocaleDateString() method will use the user's preferred method for a formal date as set by either the language, nationality or date style preference on his or her computer. Most folks in the USA will get this format:

Sunday, March 19, 2006