Beefy Boxes and Bandwidth Generously Provided by pair Networks
There's more than one way to do things
 
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 taking refuge in the Monastery: (7)
As of 2015-01-27 23:16 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    My top resolution in 2015 is:

















    Results (209 votes), past polls