I'm sending post requests using GT::WWW, like so, on the client end of a plugin I'm working on:
my $url = 'http://www.domain.com/cgi-bin/rpc.cgi;
my $www = GT::WWW->new();
$www->protocol('http');
$www->header('Content-Type' => 'text/xml; charset=utf-8');
$www->url($url);
$www->post_data($xml);
my $response = $www->post();
return $response;
On the server end, I'm using:
to retrieve the POSTDATA. I know that the data was sent, as $ENV{CONTENT_LENGTH} is set to '26', the length of the $xml variable from the client application. I don't have any problems sending and receiving POSTDATA when NOT using GT modules.
Is this a bug, or is GT::CGI puting POSTDATA somewhere else other than where the standard CGI module does?
Philip
------------------
Limecat is not pleased.
Code:
my $xml = '<foo><bar>this</bar></foo>'; my $url = 'http://www.domain.com/cgi-bin/rpc.cgi;
my $www = GT::WWW->new();
$www->protocol('http');
$www->header('Content-Type' => 'text/xml; charset=utf-8');
$www->url($url);
$www->post_data($xml);
my $response = $www->post();
return $response;
On the server end, I'm using:
Code:
my $xml = $IN->param('POSTDATA');to retrieve the POSTDATA. I know that the data was sent, as $ENV{CONTENT_LENGTH} is set to '26', the length of the $xml variable from the client application. I don't have any problems sending and receiving POSTDATA when NOT using GT modules.
Is this a bug, or is GT::CGI puting POSTDATA somewhere else other than where the standard CGI module does?
Philip
------------------
Limecat is not pleased.