Beefy Boxes and Bandwidth Generously Provided by pair Networks
Do you know where your variables are?
 
PerlMonks  

Answer: How to FTP from STDOUT?

( #48186=categorized answer: print w/ replies, xml ) Need Help??

Q&A > network programming > How to FTP from STDOUT? contributed by I0

use Net::FTP; $ftp = Net::FTP->new($host) or die $!; $ftp->login($user,$password) or die $!; $sock = $ftp->_data_cmd('stor', "remotelogfile") or die $!; while( <DATA> ){ $sock->write($_,length) or die $!; } $sock->close() or die $!;

Comment on Answer: How to FTP from STDOUT?
Download Code
Log In?
Username:
Password:

What's my password?
Create A New User
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others chilling in the Monastery: (5)
As of 2014-12-28 20:37 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    Is guessing a good strategy for surviving in the IT business?





    Results (182 votes), past polls