I would like to set the time limit for my html survey form, after the time limit the script will auto submit and redirect to the thanks page.
Below is the code i used. but it come out the error message "object does't not support the propperty or method."
can someone please help me on this, thanks
CODE
<script language="Javascript">
<!--
var countdown = "900"
function doCount() {
if (countdown > 0) {
countdown--
}
else {
setTimeout('document.authenticate.submit()')
document.location = "http://www.mypage.com/thank.html"
}
window.status=countdown + " seconds left to complete the questionnaire."
setTimeout('doCount()',1000)
}
doCount()
//-->
</script>
CODE
<form name="authenticate">
..
..
..
<input type="submit" value="Submit" name="submit">
<input type="reset" value="Reset" name="reset">
</form>
This post has been edited by jilong: 22 May, 2007 - 12:08 AM