deharris2003
Programmer
I am new to javascript. What I want to do is not allow the user to enter a date that is greater than 90 days in the past. I have written the following. doesn't seem to work. Can you tell me what I am doing wrong
<script type="javascript">
function verifyDate(field)
{
var today = date();
if field < today
{
alert("date must be within 90 days of today"
}
}
</script>
<script type="javascript">
function verifyDate(field)
{
var today = date();
if field < today
{
alert("date must be within 90 days of today"
}
}
</script>