Anonymous Monk has asked for the wisdom of the Perl Monks concerning the following question:
I can transfer the file to my server, open it and then process it, but I am looking for a means to bypass the step of putting the file on my server and then deleting it afterwards.
#!/usr/bin/perl -w use strict; use Net::FTP; my $home="yada.com"; my $username="user"; my $password="pwd"; my $filename='file.txt'; my $newfile = "extract.txt"; my $ftp = Net::FTP->new("$home") or die "Can't connect: $@\n"; $ftp->login($username, $password) or die "Couldn't login\n"; $ftp->get($filename, $newfile) or die "Couldn't get + $filename\n";
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: net::ftp - reading a file
by imp (Priest) on Dec 21, 2006 at 12:41 UTC | |
by Anonymous Monk on Dec 21, 2006 at 13:06 UTC | |
|
Re: net::ftp - reading a file
by mikeB (Friar) on Dec 21, 2006 at 18:16 UTC | |
|
Re: net::ftp - reading a file
by ww (Archbishop) on Dec 22, 2006 at 15:48 UTC |