Hi Alan,
> Is it possible to use Net::FTP::Common to delete files on the host, or
> do I have to use Net::FTP or some other module?
I just added a method to Net::FTP::Common to do this. There was
already one in Net::FTP --- mine just calls that one.
Version 5.2f on CPAN has the docs and new functionality. If you need
to add it fast, just add this sub, but the samples/delete-file in the
distro has a good example of it's use
sub delete {
my ($self,%cfg) = @_;
my $ftp = $self->prep(%cfg);
my $rf = $self->GetCommon('RemoteFile');
warn Dumper \%cfg;
$ftp->delete($rf);
}
### sample use
use Data::Dumper;
use Login;
use Net::FTP::Common;
our %netftp_cfg =
(Debug => 1, Timeout => 120);
$ez = Net::FTP::Common->new(\%Login::common_cfg, %netftp_config);
$ez->delete(RemoteDir => 'tmp', RemoteFile => 'upfile');