in reply to Re^3: replace use HTTP::Lite to run a perl file that was on another server
in thread replace use HTTP::Lite to run a perl file that was on another server
As a lark try this
and if it works, SHEESHmy $all=get_response("copyorders_multiple.pl", "refID=".&trim($license +)); my ($data)=$all=~/\n\n(.*)$/s; sub get_response { local %ENV=%ENV; my ($cgi, $CMD) = @_; ## prepare proper (CGI) environment $ENV{QUERY_STRING} = $CMD; $ENV{REQUEST_METHOD} = 'GET'; $ENV{GATEWAY_INTERFACE} = 'CGI/1.1'; # add more as needed open(CGI, "$cgi |") or die "Can't exec $cgi, $!"; local $/ = undef; my $res = <CGI>; close(CGI) or die "Error running $cgi, $!"; return $res; }
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^5: replace use HTTP::Lite to run a perl file that was on another server
by huck (Prior) on Feb 19, 2017 at 21:33 UTC |