in reply to FTP with no intermediate file, to upload my program output?

Yes you/perl can. Care to share your attempts to do this with us, or do you want us to do all the work for you?

  • Comment on Re: FTP with no intermediate file, to upload my program output?

Replies are listed 'Best First'.
Re^2: FTP with no intermediate file, to upload my program output?
by starlight (Novice) on Mar 24, 2005 at 00:47 UTC
    Touché. Here is what I have after checking on Net::FTP. My problem now is in going from $myfile to MYFILEHANDLE.
    Use Net::FTP; $myfile = "Two lines\n of text"; $ftp = Net::FTP->new("ftp.myhost.com", Debug => 0); $ftp->login('user','pass'); $ftp->cwd("/example"); $ftp->put(MYFILEHANDLE,filename.txt); $ftp->quit;
    Thanks again!

      Pre-perl5.8: check out IO::String.

      Perl5.8+: you can still use IO::String, but you can also do this:

      open my $fh, '<', \$myfile; $ftp->put($fh, 'filename.txt');