Headmaster
Technical User
The actual question is: how can I print the output from another script that is already formatted as html. That is the only output I need in the script. I'm still searching other sources, but if somebody has a solution...
Here's the code I'm struggling with:
use LWP::UserAgent;
use HTTP::Request::Common qw(POST);
$ua = LWP::UserAgent->new;
$query->append('x_Response_Code','1');
my $req = POST ' [ map { $_ => $query->param($_) } $query->param() ];
print $ua->request($req)->as_string;
If I include
print "Content-type: text/html\n\n";
or
print "Content-type: text/plain\n\n";
or
print header,start_html('test')etc...
The test3 script's output is in html already, so when I return it, the headers from test3 print out in the browser as text. If I leave only the print $ua.... line, it throws up, as it is supposed to.
I'm missing something...what is it (besides lots more knowledge.)
Thanks for the replies!
Here's the code I'm struggling with:
use LWP::UserAgent;
use HTTP::Request::Common qw(POST);
$ua = LWP::UserAgent->new;
$query->append('x_Response_Code','1');
my $req = POST ' [ map { $_ => $query->param($_) } $query->param() ];
print $ua->request($req)->as_string;
If I include
print "Content-type: text/html\n\n";
or
print "Content-type: text/plain\n\n";
or
print header,start_html('test')etc...
The test3 script's output is in html already, so when I return it, the headers from test3 print out in the browser as text. If I leave only the print $ua.... line, it throws up, as it is supposed to.
I'm missing something...what is it (besides lots more knowledge.)
Thanks for the replies!