I'm trying to post from one of my subroutines in Perl a request to a Java based controller. But I'm not getting any kind of response back. I know the Java code works file because I can get a response if I post to it from a HTML form.
This is my Perl code:
use HTTP::Request::Common;
my $ua = LWP::UserAgent->new;
my $response = $ua->request(POST 'http://testserver/testing.nc',
Content_Type => 'form-data',
Content => [
method => 'submit',
ftp_server => 'ftp.localhost',
ftp_user => 'testuser',
ftp_password => 'testpass',
remote_path => '/home/files',
port => 22,
file_to_upload => ["$file"]
]);
Is there something wrong with this code?