in reply to Open directory - Different Server

That depends on how you are connected to that remote server. Possibilities are smb, http, ftp, etc. Once you tell us that, we can possibly tell you how you can access a directory on that server.


holli, /regexed monk/

Replies are listed 'Best First'.
Re^2: Open directory - Different Server
by Anonymous Monk on Feb 22, 2006 at 14:11 UTC
    Sorry, I will be connecting using FTP
      I believe there is a Net::Ftp module in CPAN. Really, you should look at using SSH and the module Net::SSH instead. FTP is very insecure.

      Neil Watson
      watson-wilson.ca

      So you can use the Net::FTP module which is part of the libnet bundle. See the Synopsis in the modules docs for a good example.


      holli, /regexed monk/
        Hi, I am getting connected using FTP, but when I run this part of the code it can't retrieve the names of the images files in the directory specified earlier.
        # Change the working directory $ftp->cwd($path) or die "Can't change directory ($host):" . $ftp->message; # Retrieve a recursive directory listing @ls = $ftp->ls('-lR'); $ftp->binary(); foreach $file (parse_dir(\@ls)) { my($name) = @$file; print "$name<br>"; }

        I just don't know why, since the path to the directory is right, and there are many images in that directory.