Beefy Boxes and Bandwidth Generously Provided by pair Networks
Syntactic Confectionery Delight
 
PerlMonks  

Re: net::ftp multiple files

by RhetTbull (Curate)
on May 10, 2001 at 01:09 UTC ( [id://79253]=note: print w/replies, xml ) Need Help??


in reply to net::ftp multiple files

Try this. It works on my system.
#!/usr/bin/perl use warnings; use Net::FTP; $ftp = Net::FTP->new("host", Debug => 1) || die "could not connect"; #qw(password) because my password has funky characters in it -- yours +should too ;-) $ftp->login("user",qw(password)) || die "could not login"; $ftp->cwd('./test') || die "could not cwd"; foreach (<@ARGV>) { $ftp->put($_) || die "could not put file $_"; } $ftp->quit;
Setting Debug => 1 will dump the output of the FTP session -- that will probably help you figure out why it's failing. If it still doesn't work, post some Debug output and I'll take a look at it. Regards,

RT

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://79253]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others pondering the Monastery: (8)
As of 2024-04-23 16:36 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found