Hi:
I have a problem related to redirect. Here is the senario:
There are 2 perl scripts: A.cgi,B.cgi, which are located in two different servers.
1) A user fills a form
2)A.cgi process the form and redirects to B.cgi with passing parameters. It's required that the browse displays a message like "In processing" before B.cgi finishes proceessing and redirects back to A.cgi.
Following is the script doing display message and redirect:
use CGI qw/:standard/;
my $q = new CGI;
#
#doing sth processing the form
#
print header("text/html"
;
print "In processing...";
my $url = "$q->redirect($url);
However, this script doesn;t work as expected, because the
line
print header("tect/html"
;
is before the line
$q->redirect($url);
If I rearrange them as
my $url = "$q->redirect($url);
print header("text/html"
;
print "In processing...";
I will not get the message "In processing..." printed out when B.cgi is processing.
Could anyone give me advice how to solve this problem?.
Thanks
George
I have a problem related to redirect. Here is the senario:
There are 2 perl scripts: A.cgi,B.cgi, which are located in two different servers.
1) A user fills a form
2)A.cgi process the form and redirects to B.cgi with passing parameters. It's required that the browse displays a message like "In processing" before B.cgi finishes proceessing and redirects back to A.cgi.
Following is the script doing display message and redirect:
use CGI qw/:standard/;
my $q = new CGI;
#
#doing sth processing the form
#
print header("text/html"
print "In processing...";
my $url = "$q->redirect($url);
However, this script doesn;t work as expected, because the
line
print header("tect/html"
is before the line
$q->redirect($url);
If I rearrange them as
my $url = "$q->redirect($url);
print header("text/html"
print "In processing...";
I will not get the message "In processing..." printed out when B.cgi is processing.
Could anyone give me advice how to solve this problem?.
Thanks
George