in reply to Net::FTP::Recursive - how to use rls

You can use File::Tee to capture standard output to a file as well as letting it go to the screen. Also, you need to pass the filehandle to rls with a Filehandle hash key:

use strict; use warnings; use Net::FTP::Recursive; use File::Tee qw(tee); tee(*STDOUT, '>', 'capture.txt'); my $ftp = Net::FTP::Recursive->new("ftp.mozilla.org", Debug => 0); $ftp->login("anonymous",'me@here.there'); $ftp->rls( Filehandle => *STDOUT); $ftp->quit;

Replies are listed 'Best First'.
Re^2: Net::FTP::Recursive - how to use rls
by zalezny (Novice) on Oct 20, 2014 at 20:28 UTC
    Thank You very much for Your fast support! Its working like a charm. GoToBurn - thanks also for Your suggestions. This forum is increadably fast !