Posted on 2008-10-07
The code works perfectly on its own when written in the html section.
Here is the code:
setTimeout("nextPage()", 1000*60*minutes );
//assuming you have <form id="theForm"...>
var f = document.getElementById("theForm");
for( var i=0; i < f.elements.length; ++i)
//if you want to auto-submit the form, uncomment the next line
However, I need to be able run the php code on the page at form timeout. The php code, without the form runs without a problem until I insert the above script.
With the timeout script, the form submit button is also disabled and therefore the php code does not run.
Where and How should I insert this timeout/input disable script, so that I still have the submit button of the form available, which runs the php code.