PDA

View Full Version : help w/ perl refresh


t1mmy
08-06-2004, 10:21 AM
hi, i recently started working with perl and cgi in general. i'm currently working on a web page that takes in data and runs testcases on a linux machine. however, when u click the 'submit' button i have it redirected to a page 'please wait as we process your results...'

my question is, is there a way to have the script pause as the test is being run? say for example the script generates 'please wait...', then runs the test, then generates the results html under it?

on the other hand, is there a way to have the script redirect to another cgi-script after a certain amount of time? thnks for the help

Jeepers
08-06-2004, 05:10 PM
sleep n; will stop the script from executing for n number of seconds it then continues with the next line.

dswimboy
08-07-2004, 09:43 PM
the problem with using sleep, is the browser may timeout.

you can have the submit button direct to a page, and then have that page refresh using this code in the head of the docuemnt:

<META HTTP-EQUIV=Refresh CONTENT="10; URL=http://www.htmlhelp.com/">

10, is the number of seconds before refresh...URL is the page to go to. if you leave URL blank, it will simply refresh the current page.

t1mmy
08-09-2004, 07:31 AM
ok, i'll try that. thanks for the help