Javascript submit?

They have: 56 posts

Joined: Feb 2000

I have to make a test and they want a certain amount of time to answer each question. How can I get Javascript to submit a form after one minute?

detox's picture

They have: 571 posts

Joined: Feb 2001

simple javascript timeout should do the job. I remember a site had a script like this a while ago, think it was [url]24fun.com [/url] Have a look at it.

John Pollock's picture

He has: 628 posts

Joined: Mar 1999

I think detox is right, a timeout should do the trick. It would be something to this effect I think:

Add an onLoad to the body tag (this way the time starts once the viewer can see everything):

In the head tags add the function, something like:

<script language="JavaScript">

</script>

Replace formName with the name of the form from the form tag. Smiling

Want to join the discussion? Create an account or log in if you already have one. Joining is fast, free and painless! We’ll even whisk you back here when you’ve finished.