On Mon, May 20, 2002 at 08:49:56AM -0700, jasonandmissy at cableone.net wrote:
> I am writing a perl script that ftp's the contents of a directory a couple of times a day.  I loaded net::ftp and I can ftp by the exact file name.  How would I ftp the whole directory or is mput supported with any perl module?

Not familiar with Net::Ftp offhand, but the basic structure would
look something like:

# Get a list of all files in the directory
opendir(MYDIR, '/path/to/my/dir') || die "Can't open directory: $!";
my @files = readdir MYDIR;
closedir MYDIR;

# Send each file to the remote system - -f checks that it's a normal
# file before sending, you may want to do other tests also
foreach my $file (@files) { put $file if -f $file }

-- 
When we reduce our own liberties to stop terrorism, the terrorists
have already won. - reverius

Innocence is no protection when governments go bad. - Tom Swiss